Because the balls aren’t really just free-hanging side by side in your scrotum. They are separated by a thin wall called the scrotal septum.
See [here](https://en.wikipedia.org/wiki/Scrotal_septum#/media/File:Figure_28_01_02.JPG), middle panel (warning, NSFW human scrot shot when opening via RES!).
Typically your testes are connected to the scrotum wall by connective tissue too, which prevents them from moving around much. Testicular torsion occurs when a single testicle becomes rotated, compressing the blood vessels supplying the organ. This is much more likely in individuals who have conditions in which this connective tissue is weakened or less developed.
Latest Answers