The /opt/retropie/configs/all/emulationstation is actually the same folder as /home/pi/.emulationstation, the latter being a symlink to the former.
Emulationstation reads the custom file in /home/pi/.emulationstation, then - if the 1st doesn't exist - the default one /etc/emulationstation/es_systems.cfg (installed and maintained by the RetroPie setup script).
I never got any upgrade to ever write a custom ES systems file in that folder, but I'm only using RetroPie since 4.2.0 - so it might have been a problem in the past.