"It has a beautiful nut."
Translation:יש לזה אגוז יפה.
It depends on what you want to emphasise. With the pronoun לזה put first, the statement is saying IT, IT SPECIFICALLY, has this-and-that, like "he doesn't have one, but you do." — with יש at the start, the statement is putting emphasis on HAVING the thing in question, like, "you have one of these... right?"
I'm not a native speaker, just stating how I understand this and which seems (!) correct so far
יש לו אגוז יפה He has a beautiful nut is יש לזה אגוז יפה It has a beautiful nut is It is different, no? So why it is considered as a right answer to mark both of these sentences? (Sorry but for some a reason it always changes an order of words that I have written. I Believe you will understand anyhow)
"It has" is a subject followed by a verb. We do not know what the "it" is. A tree? An animal? A bird? So we cannot decide what to put after the יש Is there a rule in Hebrew which says that you cannot use לו with an inanimate subject or even with a masculine animate subject? If the "it" refers to a dog, would you have to say יש לזה and not יש לו?
I think that because לך means "to you" (female or male, in that way that you write is "a you" for male) and the sentence refers to the nut, and nut is "it". And how as Hebrew has to have a gender the word "it" does not exist because is a neutral word, so you have to use "it" for things replacing for the gender of the object. Objects female you have to replace "it" for "she" and use לה and male things you have to replace "it" for "he" and use לו. In some cases you can use "this" (fem./male, זות or זה) but I do not understend this for a while. Sorry, I think that maybe I confuse you, but I try be clear ...