Yes, you can be burning fat while working out or not. If that wasn't the case people who only diet and don't exercise wouldn't lose fat. Losing fat is about burning more calories than you take in each day. Exercise helps increase the number of calories you burn.
for me, most of your calories are burnt after exercise which is why metabolism is the most important factor in losing fat and you only exercise maybe 30mins a day on ave so whatever happens during the other 23.5hrs during the day will have the most bearing on what's gonaa happen