the girl (priestress) had a vision (dream)... in that dream naruto died..
the girl does often have visions and can foretell the future this way (or your fate)

well basically Naruto showed up in front of her then, she told him that naruto is going to die if he helps her and makes fun of him etc.

Naruto tells her that he will be able to change his and her fate/future if he wants to... and thats what actually happened. naruto was able to change his fate.