Explanation
The burning candle inside the bottle heats the air molecules in the bottle and causes the molecules to move far away from each other.
Some of these molecules actually escape out of the bottle, past the egg which is resting on the mouth of the bottle.
Once these air molecules escape out of the bottle, the paper flame goes out, because of the lack of oxygen. The volume of air in the bottle decreases and this causes the molecules to cool down and they move closer to each other, thereby creating a temporary vacuum in the bottle.
And so this vacuum in the bottle starts sucking in the egg inside and the egg slowly gets pulled inside the bottle.