Every username is a mix between riot id and tagline. to be able to add a friend, for example, you must know the riot id and tagline of the player you want.
How to know your tagline?
Inside the game, left-click on the social button, point your mouse over your in-game name, and the riot id will appear followed by the #tagline