The QR Scanner is a function built into the DS family that allows the console to read QR codes. When it is opened through the menu in USUM, scanning the Pokemon-specific QR code will record it as "seen" in the Pokedex if it isn't already. Codes unassigned to specific Pokemon will display a random Pokemon that isn't native to Alola (and thus have no bearing on the Pokedex).
Most QR codes give 10 points each (though there are a few that yield 20). When 100 points are reached, Island Scan will become available and the game will find a rare Pokemon that inhabits the player's current island. The player then has 1 hour to track down this Pokemon; fainting or catching it ends the timer.
For 20-point codes, Island Scan encounters, and more general information, please look at the QR Scanner article on Bulbapedia. You may find a full list of assigned QR codes on Perfectly Nintendo.