In the gameplay of Sonic Mania Plus, the Character Item Box only appears in the game's Encore Mode. In this mode, the game uses a different life system; the player controls two characters at the same time and can have up to three characters on standby. When the active character loses a life, the next character in line will step up to take his place. What the Character Item Box does when opened is that it adds a new character to the player's party in case they have anything less than a full roster.
The playable character the Character Item Box adds to the player's party depends on the character icon shown on the Item Box when it is opened. For example, opening it when it shows Sonic's character icon will add Sonic to the player's party. In addition, the Character Item Box will only display character icons of characters not in the player's party. If a player has all five characters in their party however, then the Character Item Boxes will be replaced with others.