If you're the type to self-host apps on a Raspberry Pi or NAS, you absolutely need to check out Paperless-ngx. It manages scanned documents (hint: your phone can scan documents for you) so you can save them and search them.
You can email docs to Paperless-ngx, save them to a network folder, use a native app, or just upload them to the web app. It also works well with networked scanners. There are plenty of videos and blog posts to get started.