Melbourne has been lashed by wild weather that has caused flash flooding and power outages across the city and suburbs.