An accent is the way a person speaks.
Some people pronounce words differently. Often, in different countries that speak the same language the same words are pronounced in a different way. Usually they can be understood, but to listeners notice they sound different. This may, or may not, be a difficulty.
Sometimes, people will talk about someone's accent. They might say that the person has a German accent, or an Australian accent. An accent is the way you say the words. If you notice someone has (for example) a British accent, you can understand them (you know what they are saying), but also know they came from Britain.
The way a person says words usually comes from where the person was a child (where they "grew up", or their "home town") and the other people where the person lives. People learn how to say words and sentences and so they sound the same people near them when they speak.
People speaking the same language do have different accents. Even people in the same country may have different accents. Sometimes people can tell what city someone lived in when they were a child by the way that person speaks. One example is a New York City accent. They might say "bwoll" (//) instead of ball (normally // in America), like used in sports and games; or they might say "hwot dwog" (/ /) instead of hot dog (normally / / or / / in that country). It sounds different, but people still know they mean "ball" or "hot dog" when they're talking.
When first trying to learn a new language, often a person will still have the old accent from their first language. That often allows other people to guess which country or place that person lived in before.
If someone can learn another language well enough, someone may not have the old accent anymore and may get a new accent in the new language. If someone studied German in Austria, for example, people in Germany may think that person was Austrian.
Sometimes it can be confusing for people learning a language if there are more than one common accent. Perhaps it is better to learn the language with one accent so you can be less confused, and when you're good enough at the language, you can start to understand the different accents which people from different areas may have.
Regional accents change
Regional accents were much stronger in the past. In virtually all countries the regional accents were stronger in the past than they are today. Even a small country like England had many dialects, which sounded almost like different languages. The difference has been radio and television. The daily effect of hearing standard speech on the media has had an effect in reducing alternative regional pronunciation. People speak more like they hear on television, and this effect began about 1920 with the advent of radio.
Another effect has been that smaller languages have gradually got edged out, perhaps because children tend to copy the language they hear on television. If the local language is very different from the language on television, children may learn both. Welsh is a good example. There is television in Welsh, and many Welsh people can speak both Welsh and English. According to the region, one or the other is the preferred language for general conversation.