Let’s look at evidence:
Generally this stuff exists either due to old racist laws. It was illegal to not be working in reconstruction South, and white former slave owners could offer low paying jobs to former slaves. If the former slaves refused, they could be arrested for not having jobs, and due to the exception on prisoners being slaves, they could be enslaved again legally.
Vagrancy and loitering were banned in what’s called the “black codes”.