Identity versus role confusion is the fifth stage of ego in psychologist Erik Erikson's theory of psychosocial development. This stage occurs during adolescence between the ages of approximately 12 and 18. During this stage, adolescents explore their independence and develop a sense of self.