There are two methods people use to get images from games, depending on the console it appears on.
The foremost and easiest method is a screenshot, which can be done for PC platforms (through video capture programs, or sometimes just PrintScreen), console games (through AV cables), and handheld systems (through emulators, or, depending on the system, AV cables). This tends to work best for 2D sprites.
The other method is extracting it from the game's code. This is usually more difficult as it requires an elaborate knowledge of how the game is stored (which differs from game to game), as well as a method to display that code as an image. This tends to work best for 3D models.