Imprisonment is not really about moral retribution, or vengeance. It serves mostly to ensure that the criminal can't commit his crime again (at least during the time he spends in prison), which gives his victims and the whole society some peace of mind.
Also, it can be argued that prisons really don't have a reason to exist, justice system could function with only two types of punishment:
For light offenses, like shoplifting or small scale drug dealing, or white collar crimes like insider trading you could go with community service, fine, asset forfeiture.
For serious crimes, especially those that include significant amount of violence (armed robbery, rape, murder) you could go straight to death penalty, with relatively short waiting period between the sentence and actual execution.
That's how it worked for most of the human history, and proved to be simple, cheap and effective.