Who said anything about sex? The song doesn't actually explain anything more than "boys pee with this and girls pee with that". Of all the ways children could learn that (and they are going to before they finish kindergarten, one way or another), I think this song is probably the best.
usually children already learn about "pee" before kindergarten