Moody’s downgraded South Africa’s sovereign credit rating to junk status, joining the other two major agencies.