There are plenty of new items that were added during the 2.0.0 update for Animal Crossing New Horizons. While some of these items are able to be crafted, others are either bought from the stores or purchased through the Nook Terminal in the Residential Services building. The pergola is one of the items you will need to purchase.
Head over to your Residential Services building and use the Nook Terminal. Select the redeem Nook Miles option and scroll down to where you find the pergola available for sale. It will cost you a total of 4,000 Bells. The item can be bought multiple times. Unfortunately, it doesn’t have a crafting recipe that you can obtain yet.
As with any item purchased from the Nook Terminal, you will need to wait a day before it arrives. Wait out the time or skip ahead in time to retrieve the item from your mailbox. Once you have it in hand, you can place it anywhere on your island. You can also take the pergola to Cyrus on Harv’s island if you have his customization shop unlocked. Cyrus will be able to customize the pergola with different wood and flower colors. Customization costs roughly 5,500 Bells.