The substance should be in liquid state.
First, it takes up space in the container, which leads to that it shouldn't be a solid, because solid doesn't change its shape easily.
Second, it has a fixed volume, it's difficult to compress the substance, therefore it shouldn't be gas too, as gas can be compressed easily.
Therefore we're left with liquid. And both of these given properties fits the property of liquid.