I write this answer not being completely certain, what results you desire from your rating system. So I will consider both possible demands. Short answer: I think the ELO system handles the situation you ask about in an arguably favourable way. So I do not think you need to worry about handling any situations "manually".
If two players A and B, with player A being a lot better, play a lot of games against each other (this situation is often prevented by some kind of match making algorithm or authority), the rank of player A will grow fast as long as their rating is close, and will slow down in growing when A wins a lot of games, since the algorithm is expecting him to win with a higher certainty. (And expectation values decide the bonus you actually receive when winning)
So yes using this system will only provide a slow way to cheat. And it is the only logical way this system could work. The system is not primarily designed to reward won games (as in quantity), but to rank players against each other regarding their skill. So wins should and do only change the rankings as much as they differ from the expectations.
If you want the amount a user plays your game to contribute directly to his points (e.g.: rating = 100*(amount of wins) + 50*(number of draws) - 75*(number of losses) + (arbitrary start value)), the ELO rating is not what you are looking for.
Considering friend vs friend games: You can - in principle - use these games to change ratings, for the reasons I have listed above, but should keep in mind that playing against a friend might have a different competitive nature than playing against a stranger. I might not care as much about loosing against a friend or I might care a lot more.
Every case in which one player gives up a game he could have still won, might confuse the ratings, because the winner might not have been the actual better player. Friend vs friend games can be a special case where giving up happens more often, but it is only a special case. If you do not want to worry too much about giving up, rest assured in knowing that "wrong"/"lucky" wins will be corrected in the long run.
Main source: ELO Wikipedia Article, good explanation of the basic principle.