Genitals are between the legs of every vertebrate. In those that don't have legs, it's between where the legs would be (the fins of fish) or where they were (the legs of reptiles that evolved into snakes, which still have them there). They got that way because they're an outgrowth of the excretory tract. In other vertebrates, the excretory and reproductive orifice is the same. It took the mammals to build it into a separate set of genitals.