I read an article on the Roblox Developer Wiki and also used some scripts found on Google but I still could not find a way to hide the leaderboard. This doesn't work, tried a Script and a LocalScript:
game.StarterGui:SetCoreGuiEnabled("PlayerList", false)
Am I supposed to put the script in a different service? At the moment it is in ServerScriptService.
To fix this, put it in a LocalScript in StarterGui. Thank you, kujekmarek.