If only it weren't for a casebook ruling that makes up a ruling out of thin air. (Somebody else probably has the casebook in front of them and can point it out).
Bob M has stated this many times. There is no rule that addresses where to enforce a foul where the end of the run is in the end zone but the results of the play is neither a safety nor a touchback.
This is not a safety because the force that put the ball into B's endzone was A's pass and the foul was by A after the change of possession.
This is not a touchback because B fumbled the ball out of the end zone and succeeding spot is where it went out of bounds.
Because there is no rule support either way, either argument is valid. Given the casebook ruling, that adds more weight to enforcing this from the 20-yard line.
Hang your hat on this. The Referee makes a ruling as he see fits because it isn't specifically covered in the rules