the rattle is actually at the rear of the headliner, where it presses against the rear windshield. there's a thin foam strip that runs across the top and that's where the noise is coming from.
when my rear windshield was smashed (by that damn tree!!!), i had my mechanic fix that for me. all he did was remove that foam strip and since then, it's been rattle free. BUT instead, now i have little broken pieces of smashed glass making even more noises.