Anything described as penal has something to do with legal punishment. Prisons are one important part of a country's penal system.
Whenever you see the adjective penal, you'll know it has to do with court-ordered punishment. A government's penal code, for example, is a list of crimes and the punishments imposed for each of them. You might notice how similar penal is to the word penalty — in fact, they both stem from the same Latin word, poena, and the Greek root poine, both of which mean "punishment."