Short answer: model layer.
Most forms of storage are part of the model layer (excluding templates and autoloader for the class). In fully implemented mode, you should have a group of objects that directly interact with low-level abstractions (SQL, cache, REST API, noSQL, file system, etc.).
If the application actively reads and writes to the file system (in fact, it can be mounted with the remote memory that you installed via Fuse through the SSH tunnel .. it does not matter), this will be handled by structures that deal with the logic storage. Usually some form of data mapper (it is also believed that repositories , units of work , DAOs and / or some similar structures).
Storage abstraction is usually responsible for storing data and retrieving data in objects. In a large-scale application, this interaction between domain objects and logical storage structures is contained in services to isolate the business logic of the application and the domain from leakage in the presentation layer.
source share