Click the Apple menu.
Then, go to System Preferences > Click Security & Privacy > Privacy tab.
Click Screen Recording.
Click the lock icon to make changes.
If required, enter your admin password.
Finally, click the checkbox next to Microsoft Teams.
A notification window will ask you to restart it. Agree.
Then, try again and see if the issue persists.