.....the following reaction occurs.
The magnesium oxide is a finely divided white solid, and CAN be lost during the exothermic combustion reaction. Nevertheless, given complete combustion (which is a given in these circumstances), the ratio of magnesium atoms to oxygen atoms will be 1:1 whatever mass of the combustion product you collect. And thus