Children are more aware and more sensitive to immodesty at earlier ages than I think most people realize.
I think modesty between siblings (even same gender), and between parent's and children, should begin right away. We taught our kids' about privacy and not leaving doors open when going to the bathroom or changing from the earliest ages.
Even being in pajamas outside of our bedrooms is a relatively recent happening....
I have a relative who bragged about how open minded her household was and how she and her husband would walk around in the public areas of their household without clothing on in front of their young children. I shudder to think at the embarrassment and shame those children felt and the utter indecency of their household (there was/is also no regard for ratings on movies, games ...other filthy 'reading' material left around) ... The kids' are now 10.5 and 13 and I just hope and pray they can recover from the abuse heaped upon them in the name of broad mindedness.
I stopped taking my son into the ladies' restroom with me when he was about 7 ... which was really because I had no choice. I was afraid for his safety going into a men's bathroom, because of the perverts that might be in there. Unlike a pool changing room, however, the bathrooms have stalls and doors and locks ...so neither our son or daughter have ever seen anything indecent.
Even little girls can be scarred by the exposure of nude women in a changing room situation. Frankly, I found those women horrifying!
I don't think modesty should just be a concern for differing genders, but the same gender as well. There's no need to walk around undressing in front of people, even relatives of the same gender. My mother and grandmother were "open" in that way, and I hated it as a kid and would always try to either leave or at least look away.
God Bless,
MrsZ