Is one method better than the other?
As with most things in UX design, we need to be able to set some objectives to measure both options against each other.
Responsiveness:
The traditional radio button would scale better with additional options or longer texts. It also doesn't require additional engineering work to control the display.

However, the modern option would require special treatment once the number of options becomes more or the text within the options become longer.

Accessibility:
Radio buttons are generally more accessible since they have been around longer and most screen readers can read the value within the HTML code, I cannot say the same for the modern alternative option you have proposed.
Readability:
It's generally harder to scan things horizontally, especially when you have more than 2 options. It's not impossible but the vertical listing is the most expected by users.
Usability:
From your example, it's hard to know what the clicked state for the modern selection would look like. But I checked bootstrap documentation, and this is what you will get if you have just 2 options. With this, it's really unclear what option is the chosen one in the modern selection controls.

But you can merge the best of both worlds. By combining the aesthetic appeal of the modern version, with the enduring usability of the traditional approach.
