This does not need to be another human player, this can be done with an NPC. Just make sure you already have a second instrument on you.
Some NPC's will ask for an instrument as a quest. For me, I found a Rocker Girl (she wears turquoise and black clothes, and has bright pink hair) in the Spooky Woods, and she wanted an electric guitar. I also found a Skater Girl (black clothes, purple striped arms, with black and purple hair) in the scrapyard biome who wanted the same thing.
When you hand over the instrument for the quest they will start playing it straight away, so simply pull out another instrument and play with them!