Minor note but many games did have ram in cart space (that's how battery backups worked, but games also used the ram for other things - most didn't need 4kb+ just for saves), so some codes were ram freezes. The game genie just couldn't force anything in system ram because it would cause bus conflicts.
Also patching isn't really the right word either. They were more like conditional freezes, because of bank switching. The game genie had no idea what bank was loaded at any given time so the codes say "if this address is this right now, make it that instead" so it would (ideally) only be active when the right bank was set. But that's why some gg codes had weird side effects, because they were affecting other banks than the important one.