Go to System Preferences > Screen and in the first tab Screen, at the bottom, you'll see AirPlay Screen. Make sure both the Mac and Apple TV are in the same wi-fi network so you'll find your Apple TV in the dropdown menu. Choose the Apple TV and type in the password shown on the TV to connect. You'll now see the icon on the Menu Bar, which is not the classic AirPlay rectangle with a triangle, it's just two rectangles. in there you'll find the options to mirror or extend the screen.
I tested it to get the right answer for you because the support articles got me a little confused.
P.S.: I believe Apple is touching things a bit on this area because there are differences between support articles in different languages. If you are curious enough 🙃
US version - Use AirPlay to stream video or mirror the screen of your iPhone, iPad, or iPod touch - Apple Support
UK version - Use AirPlay to stream video or mirror your device’s screen – Apple Support (PT-BR version is also like this one)