Thousands flee attacks in Nigeria, clashes continue, says UN