What are the 5 basic functions of prisons?

Basic functions of prisons

The basic functions of prisons today are as follows:

i. Social isolation and confinement, i.e., to isolate an offender from society because he has proved to be a threat to its organisation, stability, and cohesion, and to keep him out of circulation and so securely confined that his deviation from law does not disturb the peace of mind of the man in the street.

ii. Repentance, i.e., to keep an offender in an isolated place where he could ponder over the consequences of his wrong deeds.

iii. Punishment and deterrence, i.e., to inflict some pain and suffering, on an offender (i.e., some punishment) for violating legal norms, so that criminals should be worse off than the poorest of honest citizens; law-abiding individuals must be satisfied that law-breakers are penalised and they are being protected against the threat of recidivism; and members of society may be deterred from committing crimes.

iv. Protection, i.e., protecting community from criminals by marking out persons who violate laws and stigmatising them so that others are warned against them. J Criminal = Deviance + Prosecution + Stigma

v. Reformation, i.e., to change offender's values, motivations, attitudes and perceptions and to resocialise him and restore him to community.

But are these functions shared by the prison personnel with the law-framers? If yes, what means do they adopt to accomplish these purposes? Why is there split between the managing and the managed groups, i.e., between the inmates and the prison staff?

It is because of the stereotyped hostile and antagonistic attitude towards each other, or because of the inefficiency and incompetence of the staff, or because the staff has to function within a structure of limited freedom and formally prescribed framework of social distance which restricts their initiative for new programmes of reformation?