The tabernacle, which held the ark of the covenant, was at the center of the camp. This was so the people would know God was present there (Deuteronomy 23:14). If someone had a skin disorder, they had to live alone in a place outside the camp. This prevented the spread of infection and kept holy things cermonially clean.
Even Miriam, the sister of Moses and Aaron, spent seven days outside the camp (Numbers 12:15). This area was not just for those with skin disorders. They also burned uneaten sin offerings (Lev 4:21) and executed criminals there (24:14, 23). They took dead bodies there to keep the living area ceremonially clean (10:4–5). People also took care of bodily functions outside the camp (Deuteronomy 23:12–14).