Elon Musk sold $6.9 billion of his shares in Tesla Inc., the billionaire’s biggest sale on record, saying he needed cash in case he is forced to go ahead with his aborted deal to buy Twitter Inc.