In most Nintendo Switch games, you'll need to add someone as a friend before you can start a game specifically with them. And remember that to play games online, you'll need to have a Nintendo Switch Online subscription. You'll add friends using your Friend Code.