That’s what i tend to fit, it replaces the drive inside the system.
This is a pretty good guide for doing it
If you want something to plug in the back then just a normal external HDD would work.
It’s good idea to have a time machine backup even if the machine works fine. You never know when it will save your bacon if you accidentally delete something or if tge system gets stolen.