I think its just a natural outcome of everyone trying to build tall buildings, and given the level of technology all realizing that if you make them smaller as you go up they are more stable.
IIRC correctly from a History Channel program on it, the pyramid form developed from ancient burial techniques. Early Egyptian rulers had a square or rectangular bunker built over their tombs. Then one self-important one had a smaller, symetrical layer added on top so his would look taller. Successive rulers added to that idea. The earlier large pyramids looked a lot like the Mexican-culture stepped ones.
The pyramids we recognize today are they result of the evolution of that technique with the "step" parts filled in to make it a smooth slope.