After spraying a whiff of perfume in a corner of a room, soon the smell will reach the other end of the room. How does this happen?

You are right. The gas has the capacity to occupy the volume of the container that contains it since its particles are in constant movement, due to the fact that there are no barriers the gas will disperse throughout the room.
the answer is because gas particles are in motion