An insurance broker who posted abusive messages about Northern Ireland’s first black mayor has been jailed.