First let me note once again that I am not Jewish, but when encountering certain things I often like to explore how Judaism considers those things. Either way, today I was reading Devarim I came across the following verse (22:5):
לֹא-יִהְיֶה כְלִי-גֶבֶר עַל-אִשָּׁה, וְלֹא-יִלְבַּשׁ גֶּבֶר שִׂמְלַת אִשָּׁה: כִּי תוֹעֲבַת יְהוָה אֱלֹהֶיךָ, כָּל-עֹשֵׂה אֵלֶּה
A woman shall not wear that which pertaineth unto a man, neither shall a man put on a woman’s garment; for whosoever doeth these things is an abomination unto the LORD thy God.
Now, when I looked it up on the internet I found out that you call this prohibition beged isha and to my surprise I encountered the following exception
Further, it would be permitted for a man to wear one item of women's clothing for some functional reason -- e.g. he is stuck in the pouring rain and only has a woman's raincoat.
In this primer on the prohibition on Aish.com. Now, to be very clear here, what I am trying to understand is how this exception came to be. It's not the topic itself that interests me as much as the fact such exception exists. How I understand it is that Rabbi's often interpret the Torah in a certain and that's the way it is for the rest of time, sometimes prohibitions get added, but this is the first time I have consciously seen that an exception like that is created.