It would help if you actually referred to the browser app you're using. They all have different feature sets and there's a lot of variances as far as user interfaces. Samsung's default browser? Chrome? Firefox? Brave?
Offhand, it sounds like your browser app is set to some kind of 'restore previous session at startup' so until you intentionally close all those previously opened web sites they just keep getting reloaded when you start up the app. Or just more supposition, some exploit has inserted a bunch of junk pages into your chosen web browser app's start up page option. Go into that web browser's Settings/Preferences/Options menu and see what's listed in its startup page option. If that doesn't show anything out of sorts, try going into your phone's Settings >> Apps menu, find and open the web browser app entry, tap on Force stop, and then find and tap on Clear cache. If all those websites still show up when you start the browser app again, you might need to use the Clear data option instead. Note that wipes all the browser app's settings and configuration files so any changes and things you've previously made to your web browser app will be deleted.
Are all or some of those pages that are automatically showing up sites you've visited previously or are they just spammy, junk sites or something like that? This could determine whether the problem is just a maintenance mistake or an actual compromise of some sort.