Assuming this is your shared, marital residence, he can only legally do that if he's got a court order in place to back him up. You said you're "going through a divorce", but not specifically what's happened with that. The court can, but won't unless requested, grant what's known as "temporary orders" while a divorce case is still pending, to try to make things go smoothly and fairly for both parties. They can affect things like access to homes, bank accounts, and kids, and responsibilities to pay bills and expenses, and bar things like harassing conduct by a spouse. If you don't have funds to afford somewhere to live, but you're okay with moving out, you might be able to have him ordered to pay your rent for a time until you can get on your feet. You also might be able to have things switched around so that HE has to move out, depending on the circumstances. If temporary orders are already in place or are needed by you, though, you really do need to retain an attorney, because they're just not a simple DIY thing, and the consequences of either drafting them wrong or violating them can be severe and lead to long-lasting problems. Good luck.
Sign up to receive a 10-part series of useful information and legal advice about the divorce process.