An experimental study of the formation of an ice crust and migration of water vapor in a comet's upper layers