There are alot of problems in Mame, and cheats just work really well in mame2003, but this core is not suitable or working with later games. But if you copy cheat.dat to the /share/bios/mame2003 folder and enable cheats in mame.ini, with tab in the games you can in general see and modify or toggle cheats on/off, and they will be in this state the next time that you load mame2003. Fine.
Retroarch is for no help here, as Retroarch awaits .cht files and cannot load the different mame cheat files.
Now, from MAME 2010 on, the cheats becomes .xml and in MAME 2010, they are all packed in a file cheat.zip to copy to the folder /share/bios/MAME 2010, that is the theory.
Or, for some dark reason, MAME 2010 cheats are not working at all in Batocera or Recalbox, with tab menu, the line "Cheat" is missing and no way to make it active, but perhaps somebody will arrive, I did'nt.
From MAME 2016 on, cheats are working again. By chance, most games working under MAME 2010 works also under MAME 2016. The difference, the packed cheat file with the .xml inside is now packed cheat.7z. The destination folder follows the same system. Now you can also extract the game.xml individual cheat file and modify it and copy it under /share/bios/MAME 2016/cheat subfolder.
The sh.t problem from this later MAME's is that there is no way to have (like in mame2003) the cheats menu toggle enabled at startup of the games, you must always make this by hand, and every time.
I digged some hours around this and found no solution and Pugsy seems to confirm the situation.
The main problem with Mame shooters is the reload. This is annoying and in emulation you mostly have no pump-gun like in the real machines and shooting out of the frame is the same silly. So, for me this is the cheat that I will need all the time. But there is a simple way to resolve this problem, with no cheat at all. You must just in the second line of Tab Menu / Input (this game or this machine) put the reload key on the same button as the shooting key, and this way, with every shot you reload also your guns without cheat use.