Users a b and c all at some point search for information on products x y and z. Many users, many products.
User d comes along and has previously looked at product z and is now searching for product y. It's now worth putting product x in the "you may also be interested in" segment. It might land a sale, it might not. That data can then be added to the pool to decide if they should show product x to people who search similar products
Why bother at all if they didn't purchase? You don't know why they didn't purchase. Maybe they were shopping around, maybe they were price matching, maybe they just don't have the cash right now.
It's machine learning, not if statements.