Gobbos wouldn't ransom, other races would work. Gelding the prisoners would be hilarious.
It would also be a form of torture, which dwarves are VERY against.
I think forcing them to fight would be interesting.
Wait.....you don't......or are you talking about each other.
Dwarves against torture? It does not seem that way from most of the games I have seen played. I have seen everything from goblins used for live archery practice to roasting them with magma to restraining them in cages while giant cave spiders pelt them with webs. And, of course, the elves entombed forever in stone. Not forgetting the forgotten beast poison experiments, which are something straight out of Unit 731 (if you have never heard of Unit 731, let your ignorance be blissful). Maybe it is just the perversion of players which makes them behave that way. I remember seeing once on the wiki that "humans oppose the torture of animals", which makes absolutely no sense whatsoever if it is based on humans even today, never mind in years gone by.
While, given the acts of widespread sadism common among dwarves, it is unlikely that they would have any qualms about gelding prisoners, doing so, or otherwise mistreating prisoners, should make enemies very unlikely to surrender and more likely to fight to the death and try to escape, for obvious reasons. They will also desert back to their own side more easily if given the chance. When armed guards are present, they will be compliant and work as ordered, but require constant vigilance and may sabotage building projects if not watched closely enough. Knowing how much dwarves like to go on break, this is a recipe for !!fun!!...