you need a website to put banner, or ads relate to the content in your website, some company purchase advertise network to show their ads, and these advertise network will pay you... if someone visit your website click and see these products 
Example: you have a good website about technology and huge traffic, and you want to advertise with Google Adsense, the ads of Google are contextual and will display relevant content, everyday people visit your site to look for technologies information, they read the content and they see the ads of Google can be useful...
so they click on the ads to know this related infomation, this action will redirect to the website of product owners which bought advertise with Google, and Google will pay you for every click. 
You should know : although Google Adsense pay you for clicks, but you remember Google pay money for customers look for useful infomation, not for only click action... you never allowed own click to the ads on your website (if your website show Google ads), if you do this.... you account will be got banned from Google.