Wikipedia has the details on the physics and history of this little steamboat toy
Pop-Pop Boat: birthday candle powered, super simple steam engine named after the sound it makes when operating. The engine is just a metal box, heated by the candle, with two pipes coming out of it. Steam builds up pushing water out with an explosive pop- which then creates a vacuum sucking more water in to repeat the process. Patented in 1915 these were very popular in the 1940's.