Many of the inmates don’t know if they are male or female.
If individual public bathrooms are available many can be used by either sex, one at a time.
Home Depot (and many other stores) have long had a ‘family’ restroom. One seat; can be used by ANYONE!