How can the UK prevent two US companies from merging?
if the companies' activities affect competition in the UK then the CMA is responsible.
the hint is in the name: Competition and Markets Authority
Why would Microsoft listen or care about the ruling? It’s because they operate in the UK. The CMA can’t just regulate companies that don’t operate in the UK.
For reference, both Activision Blizzard and Microsoft have very significant presence outside of the US.