I expect that you have some OTHER setting that removes your history, perhaps each time you reboot your Mac, or simply each time you relaunch Safari, and some period of time has passed since the last time you opened Safari.
If you set it for One Year, or some other real interval, you can monitor that the history continues to accumulate.
The "manual" history setting may even have a bug, where it might assume that some system event triggers your so-called "manual" history setting, etc.
Leave it on some real interval other than "manual", and watch if the history is maintained during that period. You will likely be able to verify that within a few days.