Nebula, an interstellar cloud of dust consists of the smallest atoms, mostly hydrogen. Various cosmic events, e.g. supernova explosion can cause the nebula to become denser in some places. It is the beginning of a process, which ends up with forming a star because these denser places (clusters of hydrogen atoms) start pulling more atoms: the ball of hydrogen becomes bigger and bigger and in the centre of the ball the temperature grows the outer layers of the ball press onto the inner ones. At one point, its pressure and temperature (about 15 million degrees Celsius) cause hydrogen atoms connect with each other and realise energy in the form of radiation. That’s why it is said that a birth of a star is accompanied by a flash.
To easily see the beginning of the stars formation process, we made a simple experiment described by Tomasz Rożek in his book ,,Cosmos’’: first we blew out a candle – the smoke was floating straight up but when we blew on the smoke - it started spinning and becoming denser in some places. The smoke was the nebula and our blow symbolised a cosmic event (e.g. supernova explosion) that caused nebula get denser.