change player name color minecraft code example
Example: how to make your name a different color on minecraft
/team add <team name> {"text":"<team display name>"}
/team modify color <color>
/team join <team name>
/team add <team name> {"text":"<team display name>"}
/team modify color <color>
/team join <team name>