Yep, burning coal is just burning the hydrogen and the carbon, in both cases the hydrogen and the carbon fuse with the oxygen in the air. Its counterintuitive as the coal has an obvious mass and the carbon dioxide doesn't. However,although we can't see it a cubic metre of carbon dioxide will have a mass of about 2kg. So all that is saying is 1kg of coal will create around 1.5-1.8 cubic metres of carbon dioxide going up the chimney.