Between lawsuits and demand letters, Elon Musk’s various companies are being scrutinized—even in cities where they were once welcome.