Nothing wrong with the analogy; the Prime membership is like a little Costco nested within Amazon.
Costco could run a parallel retail outfit (also visibly Costco branded, like "Costco Open" or something) where anyone can walk in and buy anything, but not some things that are available only in regular Costco.