A prison doesn't have to be private to have a profit motive. Many prisons are built to provide jobs (corrections officers, admin, services) in their localities. Many prisoners are housed far from their homes. It can't be beyond notice to elected representatives that closing the prisons would affect their constituents.