An idiom is a phrase which cannot be understood by just looking at the words. You need to learn them because you cannot figure them out any other way!
Let me give you some examples - see if you can understand this paragraph (I'll put the answers at the bottom for you, but try it alone first)
Pull your finger out! I'm no agony aunt, so don't spit the dummy. And don't tell me you've a hitch in your giddy-up or I'll take the Mick. You thought it was all beer and skittles, right; you're in your salad days? Well, you'll be thick as mince if you don't know the difference between "up the stick" and "up sticks!" Are you all mouth and trousers or all hat and no cattle? Would you say you're a man of parts, a man of the cloth, a man of letters, the man on the Clapham omnibus, or the Vicar of Bray? You might just be a young turk, or hairy at the heel! All and sundry is going to go all pear-shaped if you don't wise up. Well, I suppose she'll be apples.
Hmmm ... still think you don't need to learn idioms?
How many of those did you know? Did you try to look any of the words up? Didn't work, did it?
Unless you know an idiom, you can't look it up by defining the words - after all, people who die don't really kick a bucket, and cats and dogs don't really fall out of the sky in a heavy rain.
Idioms are just part of the language that you have to memorize so that you can understand what people are saying. Like slang, they change and shift meaning as people develop new ways of saying things.
What's that? You want to know what the paragraph means?
If you click on the Related Question below, you can find links to the websites that I used to find some of those obscure idioms, by the way!
Here are the meanings of the idioms I used above:
Chat with our AI personalities