If such a mission were to take place, it would happen in no less than three parts. First, Martian soil samples would have to be prepared for collection. Luckily (or more accurately, because of NASA's foresight and good planning), that part of the mission will be relatively simple because the groundwork is already in place. The agency's 2020 Mars rover is already equipped to collect samples of Martian soil for later collection. Additionally ESA's ExoMars rover (set to land on the red planet in 2021) will drill into the Martian surface and collect samples.
The second part of the mission hasn't been designed yet. It would consist of some sort of rover and lander that could set down near one or both of these rovers. The rover would head out along the Martian surface and collect the samples left behind, bringing them back to the lander. According to the ESA, the lander would have some sort of small ascent vehicle attached which would launch into orbit once all the samples were aboard. This would be the first rocket launch from Mars.
Finally, a spacecraft launched from the Earth would rendezvous with the ascent vehicle in orbit of Mars and collect the samples. The craft would then head back to the Earth; once it landed, it would be placed into quarantine before being analyzed by scientists.
It's an ambitious plan, to be sure, with a lot of "ifs." But, considering we probably aren't getting humans to Mars anytime soon (at least, not through NASA), it's a great way to explore Mars without having to send humans to the red planet. It will be interesting to see what the ESA and NASA say about the feasibility of the plan over the next year.