Based on personal experience I have found that there are many different things that website owners base their advertising rates on. Some base their rates on the amount of traffic their site receives, some on how well their website ranks in the search engines, some base their rates on similar sites and their rates.
It really does vary from one website owner to another. As
@ProfMike stated, the advertisers need to advertise on sites that have a target audience of the types of people that they are interested in having their advertisements shown to.
Based on my own experience, when an advertiser places an advertisement on a website it might not perform perfectly at first but over time that advertisement can start to grow in worth and produce better results over time.
One of the tricks to finding the best advertisement spots is to find people that might be interested in what you are advertising. One thing that can help advertisers out sometimes is to change the design of their advertisement to look a little different.
Some ads perform well on one site but poorly on another and can be, in part, based on the look of the advertisement. Changing your ad can yield better results for the advertiser and that can make the advertiser happy and that leads to more money for advertising for you.
Back to what you asked. There are just so many things that website owners base their advertisement rates on that it is hard to know exactly without asking the site owner. What I have usually done for my sites is to see what similar competitor sites are charging and go from there. That's a decent starting point at least.
Hope this helps.
Cheers, Dean.