Cuban President Raul Castro said that he would leave power in 2018, just hours after he was sworn in for his second term.