The jerks created by coughing can put pressure on the chest, neck, and head, leading to a headache.