The principle of giving people what they deserve - even if what they deserve is negative - is one of the most important pillars of Protagonist Morality. This is unfortunately one I cannot provide any logical argument for, because the most important things about morality are not the things that can be proven. They are the axiological things, the things that must be learned through conscience and not reason. Retributory Justice is one of those. So I will not give an argument for it. I can, however, refute a few of the common objections to it.

1: "Punishing people for their wrongdoings doesn't make them good people." (Perfect Solution Fallacy)
That's completely true. You know what else is true? Feeding starving children in Africa doesn't change the aspects of human nature that create poverty, so let's not do any of that either. You see the problem? For any good action, you can name another good objective that it doesn't accomplish. But that doesn't make the action wrong. No action furthers every good objective. So just because there's one good thing punishing bad people doesn't do doesn't excuse us from the duty to do it.

2: "Punishing people is sometimes okay as a deterrent for future wrongdoings, but to do it just for the sake of some abstract idea of 'Justice' is pointlessly hurting people." (Double Standard Fallacy)
Well you know what? All of Morality is about fighting for some abstract ideals that don't serve any purpose other than themselves. Why should you feed starving children in Africa if you can? Surely just doing it for the sake of some abstract idea of 'Kindness' is a pointless waste of energy. You see, any virtue can be mocked this way. There is no 'purpose' to being good. It's an end in itself. And if Kindness can be justified that way, then so can Justice.