Some do, and which ones depends entirely on the game. Anything that unlocks a cosmetic option — a mask, a costume, an alternate skin — is usually the kind of thing that genuinely functions.
The broader picture has shifted, though. Cheat codes were a fixture of the cartridge era, but the move to online play and server-side saves made them largely obsolete. Anything that affects progression or multiplayer in a modern title is blocked or bannable.
And be sceptical of "cheat" downloads from unofficial sites. That's the most common delivery method for malware dressed up as a game hack.