Why did he need to kill them to get their foreskins?
In a sense, he didn’t! In fact the context of the story is that they couldn’t be converted (which is why they still had foreskins), and had he successfully converted them, they would have given up their foreskins as part of the process. But since they refused to convert, he “converted” them anyway. Either way, a W for daddy king over there, and also a partial genocide for David. The guy really fell off after the thing with the giant.