To say that George killed Lennie out of friendship would be overly sentimental. Steinbeck was writing a realistic or naturalistic novel and trying to show how such things as George's killing Lennie can and do happen in real life. Lennie has good and bad qualities. George has good and bad qualities. None of these men are noble, and Steinbeck doesn't want to pretend they are. George kills Lennie for a whole variety of reasons, one of which is to save him from being tortured and killed by the pursuing lynch mob. But George is obviously interested in saving himself, both from the lynch mob, who might decide that he was implicated in the death of Curley's wife, as well as from the law, who might arrest him for murdering Lennie. George is also concerned about eliminating a man who is becoming a menace to society, a man who might even be described as a monster.
When the men are organizing to pursue Lennie at the ranch, Curley calls to George:
"You George! You stick with us so we don't think you had nothin' to do with this."
And after George has shot Lennie and the lynch mob has arrived at the scene, Carlson asks:
"Did he have my gun?
"Yeah. He had your gun."
"An' you got it away from him and you took it an' you killed him?"
"Yeah. Tha's how." George's voice was almost a whisper.
There should be no misunderstanding here: George took the gun from under Carlson's mattress with the intention of shooting Lennie. He reached the river ahead of the others because he knew exactly where Lennie would be hiding, having previously instructed him what to do if he got into trouble. George could easily help Lennie escape by wading the shallow river and climbing up into the Gabilan mountains, but he has decided to kill him, partly because he feels personally guilty for the death of Curley's pretty wife.
George lies to save himself from any possible trouble with the law, and he kills Lennie partly to save himself from any trouble with the lynch mob. They are all enraged and thirsting for blood; they could have turned on George just because he was Lennie's buddy. This is realism, reality, real life--and not sentimentality or romanticism. In earlier novels the hero might say something along these lines:
"Yes, I killed him because he was my friend, and I will accept the consequences."
In Charles Dickens' A Tale of Two Cities, the hero goes to the guillotine in place of another man, and he says something like:
"It is a far, far better thing I do than I have ever done. It is a far, far better rest I go to than I have ever known."
That is admirable--but hard to swallow. Realism was a reaction against that sort of romanticism. George is not noble but realistic, practical, sensible. He must feel relieved to have gotten rid of a buddy who was not only a burden to him but getting him into all kinds of troubles. In Chapter One he expresses his ongoing frustrations:
"You get in trouble. You do bad things and I got to get you out." His voice rose nearly to a shout. "You crazy son-of-a-bitch. You keep me in hot water all the time."
Now George can find a wife and buy a little farm and have kids and lead a normal, peaceful life.