All matter is made of particles. An element contains only one kind of atom. A compound contains atoms of different elements chemically bonded in a fixed ratio. A mixture contains substances that are not chemically bonded, so it can be separated by physical methods. A homogeneous mixture is the same throughout (a solution, air); a heterogeneous mixture is not (sand in water).
In a solid the particles are close together and vibrate about fixed positions. In a liquid they are close but can move past each other. In a gas they are far apart and move quickly at random.
During a change of state the energy changes the spacing of the particles, so the temperature stays constant.