If you want your Mastodon account to be private, you need to do two things:
1. Set your default posting visibility to "followers-only", more info on this at https://fedi.tips/who-can-see-my-posts-in-mastodon-how-do-i-send-dms-in-mastodon
2. Switch on requiring approval for followers, so that no one can follow you without permission. More about this at https://fedi.tips/restricting-who-can-follow-you-in-mastodon
This doesn't apply retrospectively, any public posts you've already made will remain public. This just sets the default visibility for new posts.

Who can see my posts and replies in Mastodon? How do I choose post visibility settings? How do I send DMs in Mastodon? | Fedi.Tips – An Unofficial Guide to Mastodon and the Fediverse
An unofficial guide to using Mastodon and the Fediverse
fedi.tips
Link author:
Fedi.Tips@FediTips@social.growyourown.services