Clouds are made up of tiny ice crystals and water drops. To form a cloud the tiny crystals and droplets will attach to dust particles in the air. Pure water droplets will stay liquid and not freeze at 0 degrees and even colder. When this happens it is called supercooled water.
If you have the right ratio of supercooled water droplets and ice crystals in a cloud, the water droplets will then try to attach to the ice through water vapor, which will increase the ice compared to the water. This will make the ice heavier and heavier until it falls.
In our atmosphere there are different layers, each layer can have a different temperature. As the ice falls, it can fall through a warm layer of air turning the ice or snowflake back into water, making it rain.