Wtf. Like....how would you even come up with that? I'm a rather spiteful person with a vivid imagination, but if I have an enemy, there is no part of me that thinks "Heh, I should rape them. That'll show 'em". How do you even get as far as *"But is it okay to do that?"*
POWs typically has as much rights as regular prisoners, in civilized countries at least. They must be sheltered, given food and medicine, something to pass the time and so on. Plenty of regulations on this. The Germans did an excellent job with the concentration camps respecting these rules despite limited resources.
Sadly, those who don't play along by these rules might have a higher chance to win the war as they can spend a lot less treating their prisoners like humans.
Perhaps, all nukes should be held by a few neutral countries like Switzerland, and once any country disobey the Geneva convention, fighting a war without respecting the rules, then it's instantly nuked by the Swizz army.