well it may or may not be the thermocouple below is just some of what it could be.
1)Pilot flame
first you need to check that the pilot is on(lit)has it a correct size and flame pattern and is playing the thermocouple in the right place there is a hot and a cold spot on a thermocouple and it will not work if the cold spot is heated or the hot spot cold
2)Thermocouple may not be given right voltage
3)magnetic valve faulty
4)contacts could be dirty stoping voltage
5)interlock like The E.C.O. may have failed or operated
6)pilot flame may blow out from the main burner lighting or turning off (pilot in wrong place)
7,8,9……. and so on and on
GET A LICENCED GASMAN TO CHECK IT OUT
For your saftey I don’t recommend that you try to fix it.The above info is just to show you that you should use qualified people, as they know what to check and look for. Plus they have the right tools and equipment to test for all of the above and more.
Michael the gasman http://www.burngas.com