Kakashi killed Rin because he was under the influence of a powerful jutsu that made him kill anyone in his way.