* M23 demands national talks, release of prisoners
* Congo says conditions are a farce
* Deadlock threatens to prolong conflict
By Richard Lough and Jonny Hogg
GOMA, Democratic Republic of Congo, Nov 27 (Reuters) - R ebels in Democratic Republic of Congo said on Tuesday they would withdraw from the eastern city of Goma only if President Joseph Kabila agreed to their demands, which the Congolese government was quick to dismiss as a farce.
The deadlock raises the risk that the eight-month-old insurgency could turn into an all-out war in a region dogged by nearly two decades of conflict that has killed more than 5 million people, fuelled by competition over mineral resources.
The M23 rebels, who U.N. experts say are backed by Rwanda and who say they want to "liberate" all of Congo, captured Goma last week after Congolese soldiers withdrew and U.N. peacekeepers gave up defending the city.
The Ugandan military, which has been coordinating talks with M23, said earlier on Tuesday that M23 leader Colonel Sultani Makenga had agreed to withdraw from Goma with no conditions.
But the political chief of M23, Jean-Marie Runiga, told reporters in Goma his forces would withdraw only if Kabila held national talks, released political prisoners and dissolved the electoral commission, a body accused by Western powers of delivering Kabila a second term in flawed 2011 polls.
"The withdrawal, yes. If Kabila agrees to our demands then we'll go quickly," Runiga told reporters in a hotel in Goma, flanked by senior M23 officials in civilian clothes and rebels in military fatigues.
Runiga said Kabila's government was rotten with corruption, lamented the country's dilapidated roads, and said Congo's only schools and hospitals had been left by Belgian former colonial rulers. He said any talks would have to tackle such issues.
"We want the involvement of the political opposition, civil society and the diaspora so we can tackle these issues together, so that the people hear the truth and that once and for all we find a solution to the problems that have poisoned our society and politics," he said.
"We are fighting to find solutions to Congo's problems. Withdrawal from Goma is not a precondition to negotiations but a result of them," he said.
The conflicting statements indicated a solution to the insurgency in eastern Congo, which has displaced 140,000 civilians according to the United Nations, was not close.
Lambert Mende, Congo's government spokesman, quickly dismissed M23's demands.
"It's a farce, that's the word. There's been a document adopted by the region. If each day they're going to come back with new demands it becomes ridiculous. We're no longer in the realm of seriousness," Mende told Reuters from Kinshasa.
Later in the day, Ugandan military chief Aronda Nyakayirima read out the withdrawal plan to reporters, but made no mention of M23's apparent rejection of the plan.
He said the plan specified M23 would begin its withdrawal on Tuesday, and government troops would enter Goma two days later, followed by a visit by regional defence chiefs "to evaluate the situation and find out whether all these timelines were met".
NO SIGN OF PULL-OUT
The rebels on Tuesday showed no signs of an imminent pull-out and continued to guard strategic sites in Goma.
More than half a dozen armed M23 fighters dressed in crisp fatigues stood in front of the central bank building as U.N. peacekeepers in two troop carriers looked on.
"This is a sign we are in this for the long haul. M23 is digging in while the Congolese army prepares another offensive," said Jason Stearns of independent research organisation the Rift Valley Institute. "It is difficult to imagine what the possible compromise could be between the two sides," Stearns said.
African leaders had at the weekend called on M23 to abandon their aim of toppling the government and to withdraw from Goma. The Great Lakes heads of state also proposed that U.N. peacekeepers in and around the city should provide security in a neutral zone between Goma and new areas seized by M23.
Runiga also demanded the lifting of house arrest on a leading Kinshasa-based opposition member Etienne Tshisekedi as well as an inquiry into army corruption.
He said the rebels were ready to work with MONUSCO, the U.N. peacekeeping mission in Congo.
In a potential further escalation, Rwanda said on Tuesday its troops clashed with Rwandan FDLR rebels who attacked three villages on its border with Congo, but a spokesman for the FDLR denied its fighters had been involved.
Rwanda has in the past used the presence of the FDLR as a justification for intervening in neighbour Congo. But the rebel group, which experts say has dwindled in strength, has not mounted a significant attack on Rwanda in years.
Rwanda government spokeswoman and Foreign Affairs Minister Louise Mushikiwabo said they would not allow Tuesday's attack to interfere with the regional push to bring peace to eastern Democratic Republic of Congo.
"This morning's attack by the FDLR forces from their bases in DRC is clearly an attempt to take advantage of the volatile situation in Eastern DRC," she said in a statement.
"We will counter any violation of Rwandan territory by the FDLR and continue to protect our borders but will not allow today's fighting to derail the ongoing regional peace process."
Congo and U.N. experts accuse Rwanda of backing the M23 group in eastern Congo, which has big reserves of gold, tin and coltan, an ore of rare metals used in making mobile phones.
That is denied by Rwandan President Paul Kagame who has long complained that Kabila's government and U.N. peacekeepers have not done enough to drive out the FDLR from eastern Congo.