Some difficulties in Python on Begginer level

Sorry if I'm asking something dumb. I'm begginer btw. Can I somehow place multiple variables in one variable, like:

login = "user"
enter = input(login + ">")
commandLogin = "login"
commandRegister = "register"
commandExit = "exit"
commandList = commandLogin, commandRegister, commandExit

while enter != commandList:
    print("incorrect command!")
    enter = input(login + ">")

Well, in the example you're already doing that.

The main correction is that you probably want while enter not in commandList