When investors look back on 2021, one sector that will stand out is real estate investment trusts (REITs). As a group, REITs rose an impressive 40%, compared with a roughly 27% gain for the Standard & Poor's 500 Index. That's pretty amazing outperformance for a sector of the market that is specifically designed to pay dividends, not grow at a fast and furious pace. But there are some things to understand here that help explain the huge gains and why investors shouldn't be holding their breath for a repeat performance in 2022. A great year -- sort of When a market sector beats the S&P 500 Index, it's hard to put too big a negative spin on things. Simply put, as a whole, REITs had a very good year. But there's a lot of variability behind the REIT moniker that needs to be examined to understand the performance fireworks that shined so bright in 2021. Image source: Getty Images. For example, regional mall REITs rose an amazing 92% last year. This is a group that was devastated by the impact of efforts to slow the spread of the coronavirus pandemic in 2020. And, notably, the largest name in the sector, Simon Property Group, also happens to be one of the largest REITs on Wall Street, with a huge $48 billion market cap. So it has an outsize impact on both the mall niche and REITs more generally. For reference, the next-largest mall landlord is Macerich, with a relatively tiny $3.5 billion market cap. The rebounding performance here was an important driver of the REIT sector. Another notable gainer was self-storage, a sector that advanced just shy of 80%. Then there was a gain of more than 60% for apartment REITs. Once again, we see the pandemic impact. In 2020, investors were worried about a shift out of cities and toward more rural areas, which was a drag on apartment landlords. While that was a very clear trend early on, the direction quickly shifted in 2021, with apartment owners seeing fairly robust demand and a return of pricing strength. In fact, the entire housing market has been hot, leading to rising prices for houses and rent increases for apartments. This brings the story full circle to self-storage REITs, which are a convenient place to put your stuff as you are looking to move or if you are staying put but need more space. All told, these are rather unique economic rebound situations. What's the catalyst? Notably, as 2022 has gotten underway, the S&P 500 has been falling. Only the average REIT, using Vanguard Real Estate Index ETF as a proxy, has been doing even worse. Indeed, reversion to the mean is pretty common on Wall Street. So it is hardly surprising to see a sector that outperformed in 2021 posting less-than-stellar returns in early 2022. In fact, that could be the big story for REITs this year. Why? VNQ data by YCharts First off, there's that "reversion to the mean" thing to deal with. Investors often take profits in the best performers as they shift toward names with more attractive valuations. That's not good or bad; it's just the way Wall Street works. Secondly, for investors who are looking at REITs in 2022, there's a question of catalysts. In 2021, the terrible year that many REITs had in 2020 was the impetus for the 2021 gains. But now that this rebound has passed, investors will be looking for more reasons to buy in 2022. For example, do the valuations of enclosed malls justify further gains as the world still deals with new variations of the coronavirus? A rebound from extreme losses makes sense, but REITs like Simon and Macerich will have to keep putting up good, if not great, numbers if their stocks have any chance of continuing their ascent. The same holds true of apartments and self-storage (or any strongly performing sector, for that matter). It isn't really fair to look at the REIT sector as a single entity, because there are a lot of different property sectors and companies within it. Some are likely to remain standout performers -- for example, note the demand today for industrial properties like warehouses that help distribute products bought online. But even here, industrial REITs were up some 60% or so in 2021 and could be hard-pressed to repeat that performance. And then there's the issue of interest rates. REITs are often viewed as bond alternatives, recently offering both higher yields and dividend growth potential. But as interest rates rise, some investors are likely to move back toward the safety of bonds. This third issue is a material headwind that shouldn't be ignored, given that the Federal Reserve has telegraphed its intention to raise rates three times this year. Temper your expectations Nothing goes up or down on Wall Street in a straight line -- zigzagging is the norm. While REITs had a wonderful year in 2021, a lot of the gains were helped by the impact of the pandemic in 2020. Essentially, 2021 was a rebound year. As 2022 gets underway, investors are already starting to rethink valuations in the REIT sector amid broader market weakness. In fact, 2022 might be a stock picker's market in the REIT space, with company-specific fundamentals taking on a much more important role than they did in 2021. In other words, make sure you know what you own this year and that the underlying businesses are strong -- otherwise, you might be in for an unpleasant surprise. 10 stocks we like better than WalmartWhen our award-winning analyst team has an investing tip, it can pay to listen. After all, the newsletter they have run for over a decade, Motley Fool Stock Advisor, has tripled the market.* They just revealed what they believe are the ten best stocks for investors to buy right now… and Walmart wasn't one of them! That's right -- they think these 10 stocks are even better buys. See the 10 stocks Stock Advisor returns as of 6/15/21Reuben Gregg Brewer owns Simon Property Group. The Motley Fool owns and recommends Vanguard Real Estate ETF. The Motley Fool has a disclosure policy.Source