You have an Arduino board and you bought a new ATMega328 microcontroller for new projects; after mounted it onto the board you discovered it doesn't work.
Why this?
In picture beside we can see something interesting: "avrdude" and specially "not in sync"; simply it's impossible to communicate or send datas to ATMega: it's not ready!
"Ready? what does it mean"!?
Think you have a baby: he's not ready to take care of himself, but you are, both for him and for you!
Same with microcontroller: control it by external hardware (adult to baby), or give it (baby) the way to become independent.
We're covering this second aspect, that needs a little piece of code.