Nigeria has completed the voluntary repatriation of its citizens from South Africa after weeks of xenophobic attacks and anti-immigration protests, the Nigerian foreign ministry said on Thursday.