It depends on the position you're interviewing for, the intention of the interviewer, the nature of the question, and possibly the room you're in. If there is any doubt, you really ought to ask the interviewer to clarify.
If you're interviewing for a position as a database developer, for example, it's pretty likely that the interviewer is asking you to provide a data model of some sort. Whether that is in the form of UML or a formal ERD or just a description of the tables you'd create is an open question. It would potentially make sense to ask the interviewer what they'd prefer or it may make sense to just pick whatever approach you're more comfortable with. If there is no white board in the room, for example, it can be a bit of a challenge to write down a formal ERD on the pad of paper you brought for taking notes-- the interview may flow more freely if you just discuss the design verbally. If the job description specifies that you need to be fluent in UML and there is a white board in the room, on the other hand, it's probably best to produce UML.
If you're interviewing for a position as a Java architect, on the other hand, it's a lot more likely that they're interested in an architecture diagram and a diagram of the classes you'd likely create. Again, whether that takes the form of a UML diagram, a diagram using a more simplistic set of symbols, or just a verbal discussion of the components in the system, the Java classes you'd create, and what those classes would do will depend on the interview.
If you're not sure what the interviewer wants (and assuming you're comfortable producing whatever the interviewer asks for), the best answer is always to ask for clarification. The interviewer will appreciate that you're not going to just run off and start doing something when the requirements are unclear. And they'll generally tell you exactly what they're looking for.