The command /run/storeRndmStatToEvent has documentation and handling that allows for the specified flag to take on values 0, 1, 2, 3. However, in line 323, https://gitlab.cern.ch/clemenci/Geant4-srcs/blob/geant4-10.5-release/source/run/src/G4RunMessenger.cc#L323, the range is restricted to randEvtCmd->SetRange("flag>=0 && flag<3"). This means that flag value 3 cannot be set through UI commands. A simple fix is to modify the line to randEvtCmd->SetRange("flag>=0 && flag<=3").
Thanks for reporting this bug. The fix as you suggested will be included in the next release. Makoto