1)What would happen if any f-16 would accidently fly directly afterward of another one that would cause the hot air from forward aircraft's nozzle to enter backward aircraft's engine inlet? Would the engine immediately stall?
Yes, the hot exhaust of the lead's engine would be ingested by the wingman's inlet; Yes, the engine will typically compressor stall. You can actually see in the engine's performance data (from the engine monitoring system) that inlet temperature TT2 will go from say 20*F to 300*F, the stall results making the TT2 go even higher during the 'BANG", then returns to 20*F in short order.
2)What would be in case a flare which is still hot and bright would be ingested by an engine? Would it cause any damage or flame out?
It would likely cause Foreign Object Damage (FOD) to the compressor(s) and could cause a compressor stall. This would be dependent on the mass/size of the flare, and its density. (IE - How would the compressor blades fare when chewing on it?) PW fan blades are typically much more robust than GE blades. Damage limits for PW have always been very liberal in comparison to GE.
In an extreme event (multiple flares/chaff, and or broken blades) it could cause flame-out, complete failure of the engine, or even a catastrophic failure (explosive blade-out or turbine-out situation)
Best rule of thumb; if it isn't air and you can see it, avoid it going into your inlet!
Keep 'em flyin'
(Edit - spelling/grammer)