Dear Student,
Iodine is a solid. When it is kept inside a bottle with Nitrogen at 1 atm, most of it remains as solid. Now, if nitrogen is pumped out, the pressure decreases and the Iodine transforms to gaseous state more and more with lowering of pressure.
The case is similar with bromine which is a liquid.
Here, I must mention, that we are talking about thermodynamic pressure (pressure by surroundings on the system) and not kinetic pressure (pressure on the walls of a container by the atoms/ molecules of the substance).
Regards