Server list auto create servers

Hi, I recently made a menu for my game and I made a server menu for it, but I thought that there are also modes with automatic server creation: just a player came in and a server was created for him and displayed in the server list, but I do not know how to do it, and I studied the messaging service but did not really understand how to create servers using the code, I decided to ask for the help of developers on the forum, please help me write a script that will allow players to create servers

Just teleport them to a new reserved server and save that access code if you want.

how do I save the code? in data?