@johnnyD You could use NMS https://www.spigotmc.org/threads/change-spawning-conditions.440970/#post-3820006 Although, keep in mind that NMS is version specific so what is in that post will need updating to both fit your needs, and work in general.
I've never really looked into nms, are you talking about editing the EntityZombie class. I have scanned through the class itself and cant find anything related to spawning. I also looked at the post you sent, and im still confused. x)