I think with family/ close friends, it is fine to say you already have the book, especially since you had a conversation about it before, it is not just hidden in your night table or something.However, I think the way you refused the book was a bit rude, just saying you didn't need it- surely we often get gifts we do not need?