The Rotobrush is a massively powerful tool used for painting out an object from its environment, while in motion. It allows you to cut an object out onto a fresh mask, letting you change the original base layer, hide text behind an object in your scene, or place a character in a different environment completely.
The Rotobrush and Refine Edge tool are lumped together, and generally go hand in hand. The Rotobrush will work in the broad strokes, identifying the object you'd like to mask; while the Refine Edge tool will work on differentiating the fiddly little details around the edges of your object, things like hair, low contrast interactions, and out of focus areas.
Here is a pretty good walkthrough on how to use the Rotobrush, as it's a bit more complicated than we can cover here.
It's also worth noting that a new version of the Rotobrush, that is extremely impressive, has been released on After Effects 2020.