Teams allows players to form groups and share bonus XP and coins.
To invite another player to your team you must be in close range with the player. Tap the player so its in your target. You will see a button "Invite Team" on top of the screen. Tap it and it will send an invitation to that player. If the other player accepts the invitation, you will see them in the team panel left side of the screen.
To share XP/coins go into the team tab page and on the bottom of the screen make sure "share xp" and "share coins" checkboxes are ticked. Only team members who are in range and within 100 levels of you (ie. if you are level 100, only team members with level between 1 and 199 will get the shared XP/coins).
To leave a team tap the leave button on the team tab page.