Backfiring is the explosion of fumes while they are in the exhaust pipe (or possibly the carburetor). The fumes that explode are air and unburnt gas and it can't be caused by any problem that prevents combustion or even just when the engine stalls. My uncle managed to light a hay bailer afire when the engine backfired and the fire came out of the carburetor and lit the gasoline leak.
Your car could have so many different problems that cause it. To run well your engine needs to have a good strong blue spark firing good properly gapped spark plugs. The timing of the spark should be set and checked to see that it's set corrrectly and is consistent. It's possible that your wires, the coil or your distributor is broken internally or has a hairline fracture that is shorting.
It's possible that your fuel injection has dirty jets or not enough pressure. Maybe your fuel tank or filter is clogged or the fuel pump is weak. Maybe the gas in your car is old or has water in it or the wires to your ignition or through the resistor have a loose connection.
With some basic tools, an inquisitive mind, patience, and careful investigation you can find the problem. Good luck!