The reason for the absence of atmosphere on moon is that the :
The moon has no atmosphere because the escape velocity on the surface of moon is very less than the rms value of molecule. The molecules will escape and moon cannot hold any atmosphere. Also the value of acceleration due to gravity on the surface of moon is very less. The escape velocity is given Ves=√2gMR and it is 2.38 km/s for moon.
So, Value ofvrms of the molecules of gas is more that the value of escape velocity.