Many people see those who flirt as extremely outgoing people, but that is not necessarily true of all flirters. A person may be comfortable with flirting because they see it as a way to interact without making a commitment. They might use it as a way to cover their shyness, or it may indicate that they are a friendly person who finds this as a way to connect without commitment. No matter what their underlying reasons are for flirting, these people have found their own way they can connect with people in a relaxed manner.
There is really nothing wrong with casual flirting, but some people take it too seriously. They see it as an invitation to be more socially aggressive with someone, and they are often surprised when the person backs off from them. Social flirting is nothing more than making a casual connection with another person, and both people should enter into it with that thought in mind.