Everyone has an accent. If you travel to another part of the USA, listen, and announce that the other speaker has an accent, she or he is likely to respond that it is YOU who has the accent.
Accent is simply how we pronounce words, our stress patterns, and intonation. Accent is often the first impression we have of another person's language. And we judge accordingly.
Accents can be tied to different varieties:
Top third Iowa and all of Minnesota--northern dialect. Northern syntax, vocabulary, pronunciation.
Southern Indiana and further south--South Midland dialect. Ditto syntax, vocab, pronunciation.
These dialect areas are fairly broad so there are differences within them. Most of the dialect boundaries in the USA run east to west but there are a few that are north/south, primarily due to geography.
I grew up in southern Indiana and thus spoke the South Midland dialect. As in the south, we would say "Do you want a coke? What kind of coke do you want?". We moved to the Milwaukee area when I was 13, which is a difficult age and harder when you go from a small junior high to a combined 7-12 high school. With a different dialect.
Wanting to fit in, I changed how I spoke fairly quickly. I adopted the northern variety and Milwaukee slang--bubbler for water fountain. I used "soda" for a soft drink. In some parts of the city, people said "white soda" for 7-Up or Sprite. I dropped my southern-sounding accent for a northern-sounding accent. Then we moved to Illinois, north of Chicago, also part of the Northern dialect area. I attended college and university in Illinois, where if you aren't from the Chicago area, you are from "downstate" even if it's up at the Iowa/Wisconsin/Illinois border. I learned to be an English as a Second Language teacher, and deliberately trained myself to make language choices that were standard, not obviously dialectal, and as easy to hear and understand as possible.
I taught English as a Second Language in Colombia for three and a half years, working with other American teachers from various parts of the country. We had the New England contingent, who queued up and stood on line rather than in line. We had a couple of westerners, whose language wasn't appreciably distinct, and the few Carolinians, who most definitely used a southern variety. But the Midwesterners were in the majority and we, or at least I, was dismayed to hear that students preferred the southerners because they spoke more slowly!
I returned to a university job in Iowa--the top third of the state, which is still Northern. I remember going to K-Mart for a bookshelf and the cashier asking where I was from. When I answered Illinois (on the other side of the mighty Mississippi River), she said "oh, you're from back east!". Well it isn't east to me--it's midwest but ok.
And suddenly I had to learn to say "pop" for "soda", a distinction I still struggle with (generally opting for "soda pop" just to cover my bases). Folks here don't do things by accident, they do them "on accident". Sometimes they are "over to Denver" rather than "over in Denver". And I picked up the lovely, non-standard use of "anymore". In Standard American English, "anymore" is to be used in a sentence with a negative: I don't go there anymore. In our part of Iowa, we can say "Anymore the sun shines every day!" Our international students shudder....I recall mentioning this to a native speaker who denied doing it by saying "Anymore I talk like everyone else".
So the purpose of this extended autobio re dialect and accent is that everyone has an accent, we hear the differences, we judge by them (more on that judging can be found in the post Attitudes Towards Language Varieties).
It's quite possible that you, the reader, have had the experience of traveling to a different dialect area and speaking with those speakers....and perhaps, without realizing it, shifted your pronunciation somewhat to match theirs. It's a thing! And it's pretty common. There's a theory, called Accomodation Theory, that postulates that we adapt our language to another person's in order to show solidarity, friendliness, an interest in getting to know them better, and so on.
It can work the other way, too. If I dislike the person I am speaking to, or want to emphasize the differences between us, I can not only not shift towards, I can shift further away from. I can use the accent, vocab, syntax of my own variety to distinguish myself from that person. If I were speaking with Donald Trump, for example, I would use the most sophisticated vocabulary possible and speak in complete complex sentences. And I would hope to shame him, sad but true.
This can be done with languages, too, though it might be too overtly rude. I can suddenly start mixing in Spanish words or phrases with someone who doesn't speak Spanish, or use Spanish exclusively. That shuts down communication instantly and is rightly perceived to be exclusionary. Speakers of African American English might do this in front of or with a standard English speaker as a way of saying "you aren't one of us". Even emphasizing just the accent would achieve this.
So everyone has an accent. And accents are not neutral....none are good or bad, better or worse. But all are capable of sparking judgement.
note: in order to increase authenticity, actors may need to adopt a different accent. Listening to someone speaking with that accent comes first. Imitating may be second, Hearing how the vowels sound, the differences in some consonants, and especially the stress and intonation patterns, which are global and affect comprehensibility most. In some cases instruction may be needed--how to actually form and produce a sound. Language nerds might like to see the entire system, the phonology, along with the specific sounds, which is phonetics. If I can see a pattern--no short vowels in Spanish--I can apply that to all the short vowels (replace with long vowels) rather than attempting one sound at a time. BTW linguists don't use the terms long/short in the same way we were taught in elementary school, but most people understand what is meant.
Wow. Here I am, treating accents as just sounds. I know better. More important, actually, than sounds are stress and intonation. Words in English have stress: reCORD and REcord, for example. Sentences in English have stress, too. "The box is heavy" will have sentence stress on box and heavy. The and is are reduced. The American English stress pattern for a sentence is putting emphasis on content words (nouns, verbs, adverbs, adjectives) while reducing function words (prepositions, articles, demonstratives). This results in the following sentences taking about the same time to say:
The box is heavy.
The package is heavier.
In contrast, Spanish has a more regular stress pattern such that some think it sounds nearly stattaco. When I speak Spanish, I emphasize some syllables over others. When Spanish speakers speak English, they give each syllable too much attention.
Even more noticeable is intonation, the melody of the sentence. To keep it simple, English has two major intonation patterns, rising and falling. We use rising for questions that can be answered with yes/no, for example, Are you going to the store? We use falling intonation for everything else, for example, What are you getting at the store? I went to the store yesterday.
That's overgeneralizing; English does have other patterns. But it's broadly true. Other languages have different patterns--there are at least nine patterns to know in Russian. Spanish has a different set of intonation patterns, and it sometimes depends on the country or region. Many Spanish speakers will say that they "sing", as in having more rising intonation in more places than English.
So if one is trying to achieve a native-like pronunciation, it is imperative that the stress and intonation patterns be addressed; they are more salient than any individual sound.
note: Tone languages, like Chinese and Vietnamese, have "intonation" on each syllable rather than over the course of the utterance. These might include rising, falling, low, rise-fall, and so on. In Southern Vietnam there are 9 tones (!); in Northern Vietnam there are 6. Speaking an intonation language and learning a tone language is a real challenge, and vice versa, of course.