Few months ago I was going through a tutorial teaching git. There was the main branch (obviously) and then I created a second branch.
Now I'm back at learning git and when I try to see the branches available using
git branch I don't get anything. Not even a main branch which is there by default.
What could be the problem?
Thanks in advance

There is no context but I’m assuming that you are in a fresh repository.
Yes, if you then do this you will get no output:
Because you are on an “unborn branch”; you haven’t created any commits yet so there is no branch to point to.
If you however create a commit:
Then you will see the branch:
Because the branch has been born (it points to something).