Because advertising typically reinforces a products quality. Why would you try a no name brand when you buy Heinz who is the leading national brand.
If you have a vending machine selling Coke, Pepsi and Joe's Discount Soda, you're going to go with Coke or Pepsi.
Personally (here in Canada) I prefer the Noname brand baked beans over the Heinz brand due to the Heinz brand over using the hickory flavouring. However, this is because I grew up in the UK and the Noname brand in Canada tastes exactly the same as the Heinz Baked Beans formulated for the UK market.
I actually continued to buy Heinz Baked Beans for a couple years before I finally gave in and bought one of every brand to get one that tasted like I was used to.
If it wasn't for the advertising I would have likely bought a different brand of beans within a month, not within a couple of years. Why? Because Heinz is the best, surely the others must taste worse! Since then I always try the store brand and lesser brands