This article explains two ways to use Nintendo Switch Voice Chat.
Nintendo Switch: How to Use Voice Chat in Fortnite Game
Download and install the Nintendo Switch Online app on an Android or iOS device.
Open the app and sign in with your Nintendo Account. (If you don't have one yet, you'll need to sign up for a Nintendo Account.)
Start the game you want to play with the same Nintendo Account and open a mode that supports voice chat.