This is new to me, as it’s a new feature in macOS Mojave.
On older systems, to capture a screenshot, you can use Shift+Cmd+4 and either select a rectangular region of the screen, or tap Space Bar and then click in a window to grab the entire window (even if it’s partially covered up, or off-screen)
Mojave uses Shift+Cmd+5 to give you an interactive screenshot and screen recording utility that is far more flexible, and can record video. Mojave also lets you use Shift+Cmd+6 to capture a screenshot of the Touch Bar (this has been around since 10.12.2).
Source: How to take a screenshot on your Mac – Apple Support