 A state can mean a piece of land, or territory. In physics, a state refers to a physical condition, which are typically categorized as being gas, liquid or solid. "The River Ravi flows in which state?" could be interpretated as someone asking about the territory, or name of the land it flows through. In this case, they want the physical condition, which is a liquid. The joke is centered on the word "state" and its different meanings.
Q : River Ravi flows in which state ? A : Liquid .