You can choose a hotkey enable button when you configure your gamepad and this will set it also in RetroArch so you can trigger an action with 2 button combos - see https://retropie.org.uk/docs/Controller-Configuration/#hotkey.
However, this is an emulator feature (RetroArch) and not a global/general input configuration option that will work in any program (including EmulationStation).