Adding User.replace(username, user) to replace current users[username] with new user
Added User.replace function and updates test cases to include replace