Quantum mechanics treats electrons as waves. The boundary conditions in which they are contained determine the shape of waves. We get the orbital we are familiar with for a spherically-symmetric electric potential. Remember that orbitals are graphic representations of the wavefunction. The electrons don’t jump between orbitals. They are “waving” one way, then if you take away or add energy, they will ‘waves’ another. Most orbitals have a lot in common spatially.

Alec stated that they look harmonic because of their harmony. Spherical harmonics are used to model the angular dependence of an atomic orbital. There is one caveat to what orbitals look like. The Schrodinger equation can be described as an ordinary linear differential equation. This means that linear combinations of solutions are possible if there are solutions. These orbitals are not the real solutions. For example, the px, piy, and pz orbitals look dumb bell-shaped. However, the px orbitals and py orbitals actually combine the p1 orbitals and the p-1 orbitals. Because they are orthogonal and real, px and py are often used.

Many programs exist that can simulate atomic orbitals. You can search/youtube until you find one that suits you.