Is it okay for an interviewer to ask questions like that? Or am I
Of course it's okay.
Interviewers are just doing their job to the best of their abilities. And that doesn't mean you have to answer, just because it's okay for them to ask. Good interviewers won't press you for an answer if you tell them you aren't comfortable providing one.
You seriously overreacted by deciding you weren't interested in the position solely based on that question. You may have "rubbed me the wrong way" out of a good job.
Next time you are asked that question, you'd be better off just saying something like "I'd rather not say." Most interviewers will not take it any further.
The interviewer may have been trying to judge how in demand you are. Or may have been trying to determine if time was of the essence in your interviews. Or they may have simply been trying to be polite.
You can always choose to politely decline to answer any question posed of you. But getting offended by a simple question during an interview isn't usually the best approach.