Indonesia's Mount Merapi volcano on Java island has erupted, sending up a cloud of ash and prompting authorities to warn of the risk of lava flows reaching roads.