Rin kills herself by running into Kakashi’s lightening technique to prevent herself from harming her village in issue number 604 of Japanese manga "Naruto." Enemy shinobi had put a monster in her and planned to use her against the village.
The Ninja from the Hidden Mist kidnaps Rin and puts the Sanbi into her. The Sanbi is a monster with three tails. When Rin returns to the village, the Ninja from the Hidden Mist had planned to unleash the monster in order to destroy the village. Rin kills herself in order to prevent that from happening. Kakashi has a special magic technique that causes lightening to appear on his hand. Rin runs into Kakashi’s hand, putting a hole in her chest and killing her. She does this in order to save the village that she came from, which is called Konoha, or “Village Hidden in the Leaves.” In the first depiction of this scene from the manga, it looks like Kakashi kills Rin himself with the technique. However, the true situation is revealed later. Obito, who was in love with Rin, comes across her death too late to save her. He kills the ninja responsible for killing Rin with powers he that he had just acquired.