System Preferences keeps coming back to dock after every use following Big Sur update
Solution 1:
This area of the dock, separated by the lines, is your recent applications. It will show your three most recent applications, even if they're closed.
If you only want to hide System Preferences and not disable the feature entirely, you will need to open other applications (at least three) and System Preferences will be replaced.
Alternatively, you can hide this area of the dock in the Dock preferences. It is a checkbox called "Show recent applications in Dock.":