In many countries, it is not cells for 2 like you see in the movies.
But cells for 4-5-6 people.
It is a measure for saving money. A lot of countries are missing room for criminals. While some others have extra space. So sometimes you have countries sending criminals to other countries. Even that exists.
While some countries like Nordic ones have pretty nice prisons for not high-class criminals. You could see pictures on Reddit.
About escaping. It is not that common. People tend to do their time and want a clean slate, not to run their whole life from the police.
But prisons are mostly contra productive, they tend to turn people into bigger criminals than they were.
Latest Answers