Trying to change player.character but it doesnt work

Why does this not work? trying to change the players character to a model in rep storage and it doesnt give any errors

local rep = game:GetService("ReplicatedStorage")
local players = game:GetService("Players")

local characterModels = {
	Barbarian = rep.Classes:WaitForChild("Barbarian"),
	Knight = rep.Classes:WaitForChild("Archer"),
	Mage = rep.Classes:WaitForChild("Mage")
}

local function changeCharacter(player)
	local playerClass = player:FindFirstChild("Class")
	if playerClass and  characterModels[playerClass.Value]then

		if player.Character then
			player.Character:Destroy()
		end

		local newCharacter = characterModels[playerClass.Value]:Clone()
		newCharacter.Parent = workspace
		player.Character = newCharacter
		player:LoadCharacter()
		print("")
	end
end

players.PlayerAdded:Connect(function(player)
	player:WaitForChild("Class").Changed:Connect(function()
		changeCharacter(player)
	end)
	changeCharacter(player)
end) 

Try putting newCharacter into game:GetService("StarterPlayer"), then do player:LoadCharacter.

local newCharacter = characterModels[playerClass.Value]:Clone()
newCharacter.Name = "StarterCharacter"
newCharacter.Parent = game:GetService("StarterPlayer")

player:LoadCharacter()

I believe that to change a player’s character, you have to rename it to their username before assigning it as their character.