The purpose of advertising for Pepsi What is the purpose of advertising for companies like Pepsi who advertise the same product and every person in the modern world knows about it? Why waste money?
Advertising is hard to understand if you take classroom economics models too literally.  I highly recommend diving into the literature on behavioural economics if you are truly interested. But for the purposes of your question, Pepsi runs advertising because it operates in a market in which consumer choice is primarily driven by two sources of cognitive bias: the anchoring and the availability heuristic.  

On the one hand, new customers are born every day, and if Pepsi doesn't run advertising then those new customers will see a Coke ad first.  On the other, since existing customers don't actually make purchasing decisions based on a careful weighting of product merit, they need to be reminded that Pepsi exists and that there are warm, fuzzy feelings associated with the brand. This way, when they find themselves craving something to drink, Pepsi might be the brand that comes most readily to mind, because it's the last soft drink ad they saw.

This is just my opinion (built on some of the theory, but by no means do I claim it is the Complete Truth), but the anchoring heuristic in particular seems to explain brand loyalty in the cola market.  I grew up in the era of the "blind taste test" and my takeaway from those social experiments is that when the most significant product differentiation is along branding lines, consumers will tend to just stick with whatever product they encounter first, because absent labeling and the social utility that comes from a trite form of tribalism, the consumer is indifferent to the choice.