The best way to avoid damage from leaking batteries is
to not have any. Find out how to get rid of those AA
This is the location of the batteries in Bally / Williams games (WPC) manufactured in the 90's. If these batteries leak, they will damage the circuit board, usually below the batteries. Once this circuit board is damaged, it may become unusable. Change these batteries at least annually. Batteries in Williams System 11, plus Sega/DE/Stern games are in a similar holder. Newer Stern games do not use AA batteries but use coin / watch batteries. They do not need to be replaced on a regular basis since they rarely leak.
To access these batteries, it is necessary to unlock the backbox and remove the translite. On some models, it may be easier to remove the display / speakers below the translite and carefully place it, display down, on the railings of the playfield.
If the batteries are removed while the game is off, all the settings and high scores will be lost. It is possible to replace these batteries with the power turned on, but this should be attempted only by qualified personnel. If the display is also removed and placed display down on the railings of the playfield, be certain that no wires or circuit boards short or make contact. Several hundred volts are present on the display. See the caution at the beginning of this article.
Some hobbyists remove these batteries and place them in a separate battery pack located elsewhere, usually below the circuit boards in the backbox. This protects the circuitry in case the batteries should leak.
After you have replaced the batteries, it is a good idea to mark the date on them with a sharpie. That way, you can tell at a glance how old they are. If you are removing batteries that are only a year old, don't throw them out! They are most likely still good. Keep them and use them in your remote controls or other applications. You just don't want them sitting in your pinball machines for years and years.
Note that it is a good idea to go into the service menu and write down all the settings on a piece of paper. That way, in case memory is lost, it is possible to return your pin to the settings you are used to. Store that piece of paper with your settings in the user manual.