SoftBank Group Corp. will invest $2 billion in Indonesia through ride-hailing giant Grab over the next five years and plans to explore investment opportunities in the country’s electric battery and renewable energy sectors.