Like what happen to yahiko and nagato........... nagato did not intentionally killed yahiko, it was yahiko who allowed himself to be killed by nagato because of an important condition....
If Rin is like yahiko maybe she allowed herself to be killed by kakashi, remember what obito said to...