sf::Mouse::getPosition(window) gives you the position of the mouse cursor, in pixel coordinates. It has nothing to do with scene coordinates, and thus with mapPixelToCoords. These two functions do different things, and they are often used together.
By default, pixels and scene unit match perfectly, so mapPixelToCoords does nothing. But as soon as you resize the window, or use a custom view, this is no longer true. Imagine the extreme case of a 1x1 view (so all coordinates are between 0 and 1) in a 1000x1000 pixels window; sf::Mouse::getPosition(window) returns coordinates between 0 and 1000, and only mapPixelToCoords can transform them correctly to scene coordinates between 0 and 1.
The use for mapCoordsToPixels is less obvious, you're right. It can be used to map coordinates between two different views (the world and the UI, for example), like this: view_1 -> mapCoordsToPixels -> mapPixelToCoords -> view_2.