There are two ways to stop fires in the sims 3
1 You can select a sim to extinguish The flames but you will but them at risk of death but if they have the secret trait of immune to fire or brave they will have less risks
2 in the rooms with the highest risks you can place fire alarms which are located in the misc of Electricals place it on the wall of the rooms with the most fire hazards (fireplace, cookers and cakes) and if the room has a fire the alarm will sound and a firefighter will arrive to put out the flames
Hope this helps