The Raspberry Pi (or any capable SBC for that matter) can be a full-on replacement for many things in your networking ...
If you’re on a tighter budget, you can re-purpose an old PC or Raspberry Pi into a DIY NAS using TrueNAS or OpenMediaVault.