It doesn't matter whether it's on the market or not. If the owner's willing to sell and you're willing to buy, then the deal can work. (Investors do that all the time.)
No, the debt wouldn't be transferred to you. But . . .
Let's say the owner owed $100,000 on the mortgage. And let's say he's failed to pay $15,000 over the past two years. For you to purchase and get clear title, you'd have to pay $115,000 (plus any penalties, plus any back taxes, etc.) So his debt wouldn't be transferred to you, but you'd have to pay enough to wipe out the debt he does owe.
There is a technique that gets around that, in a way. It's called buying "subject to." The owner would deed the house to you. You'd pay the arrearages (back taxes, back payments, etc.) and resume making his mortgage payments. It's not assuming his mortgage; it's paying his mortgage for him. At some point in the future, you'd refinance your house into your own name, removing him from the mortgage. Note that doing a "subject to" very likely could trigger the "due on sale" clause, giving the bank the right to demand payment in full. However, it's also very likely that the bank would be delighted that someone had started paying the mortgage again--it probably wouldn't care who that person was. But that is a factor you should be aware of.
One other possibility that might or might not work--if the owner is agreeable--is a short sale.
Who do you contact for info? A Realtor or a lawyer could help you. You first have to make sure that the house hasn't been foreclosed on yet (despite what REO said.) You then have to find out about the arrearages. It's possible that some of them can be negotiated down. If you want to purchase conventionally or via short sale, use a Realtor. If you want to do a subject to, you might be better off using a lawyer.
Hope that helps.
But then the bank says you have to contact the owner? The owner would be the bank, if the foreclosure occurred. (Maybe there's some sort of redemption period--some states have that--though I don't know about Illinois.)
Where to start: Try a Realtor first. He/she can check various records and perhaps give you an answer as to who the owner is. That won't cost you anything. Then, if appropriate, you can proceed to a lawyer.
Hope that helps.
The bank may or may not have possession of it right now. 2 years ago, so maybe. But since banks don't always put everything on the market right away, they could be holding. When dealing with the bank though, if you are not going to use a Realtor, it is a good idea to use a real estate attorney to ensure all leins are settled, etc. This is not the former owner debt, but sometimes leins for grass cutting by the village or taxes, etc.
I would encourage you to have a Realtor help you though. It doesn't cost you anything. Look at Trulia for Realtors in your area.