Here's your diagram, or at least a Chinesium version. It says for 7 KW, but I doubt seriously there's any difference in the wiring of a 9.5 KW. It's a pretty cheesy drawing, but now it makes what you described a little more recognizable. Still makes no sense, but I can see what you say now with this. Ignore the bits to the right of the Charging Module (Starting motor, Starting Relay, and Battery) because you have a pull start system, but the rest of it should match up.
It does indeed look like the battery charging coil under the flywheel is connected to the fuel shut-off valve in the lower left-hand corner when the engine switch is turned to the OFF position. Contacts FS (fuel shutoff) and G (comes from the charging coil [in gooderer Engrish]) are connected when the switch is off. One more thing I just noticed is that the connection to the coil (by way of the on/off switch FS/G contacts) is that it does NOT go through the charge controller for a battery. That would mean that the coil is getting an AC signal, NOT DC. Set your DVM to AC to check the signal to the Solenoid. After seeing this drawing, I would not test that solenoid with DC. Find out what the AC voltage is from that charging coil by checking from the G terminal on the engine switch to the block. Then, you could use a variac to test the solenoid. It's typically going to be something around 24V AC, but that's just a SWAG.
Ignore the bits for the starting circuits if it's a pull start, but all the rest will be identical on the engine. It's usually pretty easy to add a starter to these engines because of them all having the battery charging circuits built in above some magical horsepower limit. The difference is in the external wiring, and now, I'm guessing the way the solenoid operates. That's about as bass-ackward as it can get, but they didn't ask me when they designed it. Normally, a fuel shut-off would be a fail-safe device, but I guess not on small generators. I'll eat my crow pie about that. It was just completely unexpected to find a safety device that had to be powered up to operate. That breaks a LOT of safety standards. But, in short, there should be no connection between that solenoid and the excitation of the generator. The source is the battery charging (sic) "Coil", not the generator output or excitation.
So, my guess of what's happening as the engine/generator spins down and gets to low speed, there isn't enough voltage output (from the "Charging Recoil") to keep the solenoid energized so it's dropping back out before the engine is fully stopped. Typically, there's only one diode in that charging circuit, so you only have half- wave rectification and NO regulation to start with, so it isn't a long reach to understand why it would drop out at low speed. This may be happening even before it's going slow enough for the compression relief to do it's thing under about 500 RPM, which would usually make it back-fire through the carburetor if it was an ignition issue. That would allow raw fuel/air mix to get dumped into the engine, pumped out into a red-hot muffler, and BOOM! Not surprised at all about the back-fire.
This suggests that perhaps the charging circuit isn't functioning properly so that it provides enough power to keep the fuel shut off until the engine's slow enough to prevent the backfire. It isn't a problem with the ignition system, otherwise, the engine would simply try to rev back up or run very poorly on a lean mix. The ignition is shorted out by the contacts at IG and E. IG is for IGnition and E is for Earth (a European/Asian way of saying GROUND). With the ignition shorted out, it cannot provide spark to ignite the fuel/air mix, but high muffler temps could certainly ignite it.
Note the Idle Speed Switch near the center of the drawing. This suggests (as well as does the stepping motor) that there IS a throttle control on the machine. Most modern generators have an "Economy Mode" that lets them idle down when power is not needed. That's a PITA feature with LED lighting because they simply don't draw enough current (only a few milliamps) for the control module to detect the load and keep the engine at full throttle, so turning the Idle Control Switch OFF makes the generator run at full output capacity at all time. If you're using it out in the boonies somewhere, that economy mode might make a big difference in how long you have power available. The benefit of an inverter output generator is that it's typically taking a DC input from the generator and synthesizing AC power at proper frequency and voltage. That makes economy circuits a little more friendly to LED lighting and lets them use a lot less fuel by idling down under light or no load conditions. Make sure nothing is plugged into the sockets, turn that switch to the ON position, and after a preset time, the engine should slow to idle. Let it sit in idle for a few minutes to cool down a bit, then turn it off and see what happens. If it still backfires, and you've tested the solenoid (with a 12V battery as suggested, but a 6V lantern battery may do the trick), odds are the charging circuit has probably spat the dummy. You can check for voltage at the fuse (straight below the Oil Level indicator in the diagram). Just put the common lead anywhere on the engine block and the positive lead on the 'hot' side of the fuse to see if the charging circuit is actually working at all. If it is, it may still be weak.
Here's a proposed test. Disconnect the solenoid, which apparently isn't really used except for shut-down. Start the generator, get it hot (plug some stuff in), Then stop it. It will likely go BANG when it stops from full speed. Start it again, get it hot, then, unplug all the loads with the Idle Switch set to ON and wait for it to slow down. It REALLY should slow down, but I have no idea how long the timer takes. If it slows to idle, let it do so for 5 minutes or so to allow much cooler exhaust to cool down the muffler. Then shut it off and see if it goes bang. I kinda think it won't because the muffler will be cooler and the compression relief should open pretty quick which SHOULD dilute the air/fuel mix some to prevent the backfire. It isn't getting a chance to do that when stopping from full speed. On occasion, I don't give my B&S 21HP Intek time to cool down and shut it off with it throttled up, and yeppers, it'll go bang, too. BUT, if I slow the engine speed and let it idle for 30 seconds or so, it NEVER goes bang. OOOP OOOP OOOP (compression relief) when it drops below about 200 RPM, but no bang. The only thing that can ignite the fuel air mix is a spark or something that's still hot. Let it cool a bit at idle before shutting it off SHOULD help.