A North Carolina State Senate candidate was arrested Monday after being accused of threatening the Cary Police Department on social media while fleeing from them with a gun, officials said.