My main teachers have a lineage coming from both Nyingma and Kagyü, so their explanations might differ slightly from 'pure' Karma Kagyü teachings, but I was told that touching foreheads is a gesture of very endearing closeness. Good old friends might touch their foreheads as a recognition of their proximity. Similarly, teachers feeling a strong bond with some students will touch their foreheads with them when the students thank them for a teaching received.
I was also told that it would be very impolite to 'demand' that a particular teacher touches their forehead with us, to somehow publicly recognize a closeness that doesn't truly exist.
Specially gentle, kind, and compassionate teachers will often never discriminate among students — they will always insist to touch their foreheads after a teaching is giving. HH the Dalai Lama also often does that to complete strangers (with some eyebrow-raising from his entourage!). The point here is that a Bodhisattva truly never discriminates among sentient beings — he or she will feel close to everybody!