It’s the same reason why you don’t allow 18 year old girls to share a dorm room with an 18 year old boy.
Co-ed dorm rooms are bad because EVEN if no one physically does anything because sinful or undesired thoughts can creep in or develop.
For example: 1) accidentally seeing roommate naked or partly naked. 2) Unintentionally falling in love with the roommate. 3) developing romantic or lustful feelings for roommate’s good friend who comes to visit
Just because you have not fallen in love with or been secretly attracted to your roommate for your roommate doesn’t mean that it doesn’t happen.
This is less about what you do and more about the struggles that go on inside.
Also, if it’s OK for a gay man to share a room with a straight man, then the argument becomes that it’s OK for a straight woman to share a room with a straight man. It’s not, but logically it flows. As someone who used to work with the Boy Scouts and was trained in Youth Protection, this is the exact issue I have with allowing gay boys to join. Who do they share a tent with when camping? They can’t share a tent with another gay boy because that would be like having a girl and boy sleep in the same tent. And they can’t have them share with a straight boy because that is still the same as sharing with a girl (at least one way). And a gay boy still can’t share with a girl (if a girl was present via a Venture Crew team) because you risk chances of the girl seeing boy parts and the girl is still sleeping with a boy. So the only chaste rooming situation is for a gay boy/man to have a single dorm room.
In college, young gay men often interact with girls (not always, but often have girls to interact with too). In the seminary, they don’t. It can be difficult for a chaste gay man to only be around men, just like it could be difficult for a straight, chaste man to be in a school only with women.