The virus doesn’t know, and we should try and understand that evolution, which is what mutations drive, does not have a ‘will’. Mutations are chance events. And it is only the mutations which provide an increased chance of survival (in this case, increased transmissibility) which then go on to be more successful and reproduce. It’s why the really nasty virus’s, Ebola for example, don’t spread like this. They kill the host too quickly and therefore can not replicate.
It’s important to appreciate that there has probably been a number of mutations which have occurred in the UK since this began. However, if a new mutation occurred which meant the virus is 50% more deadly but at the expense of its transmissibility - well it won’t cause any further damage.
I get what you’re saying there too, but the virus’s ‘job’, so to speak, isn’t to infect hosts. It is to replicate. It does that by infecting hosts yes but once you see it that way, it’s much clearer as to why its ability to spread is so important and why as far as we know, it’s very similar mutations that we are seeing here, in SA etc. That’s the key mutation in the amino acid chain which really drives its transmissibility.