So here is a world-building question to consider. In a world where undead are an accepted fact, why would people refrain from cremating their dead? Why not burn the dead down to ashes, mix those ashes with real divinely infused holy water, make bricks, and have memorial shrines that were impervious to undead energies? Then the only corpses and ghosts available would be people who died outside the cultural system. Even then, it could be a cultural expectation to try to “brick up” the corpses of the dead.
One of the main influences that I am aware of that caused Europeans to preserve corpses was a reading of Revelations in the Bible that suggests that when the trump sounds, people’s spirits will flow back into their bodies (and those bodies will be made whole.) But if you have no body, what then?
In Egypt, your body was prepared for your use in the afterlife, all tidied up and sorted and put among everything else you’d need.
What other reasons might you have to leave your dead laying around to serve as footsoldiers in the next necromatic assault?