Can bar codes theoretically be considered a type of digital memory?
There is no god-given definition of (read-only) digital memory. We can think of several reasons for a writing system to be considered digital:


Can be read by a computer.
Cannot be read by a human.
Has high density.
Designed for use by computers.


Barcodes satisfy the first two properties, but not the third one: their density is rather low. Nevertheless, both traditional barcodes and modern QR codes were designed to be read by machines, and this gives credence to your claim.