In this chapter, we find Lennie alone in the barn, worried about a puppy that he has accidentally killed. He worries that his friend George will be angry with him and will not let him tend the rabbits at the place they plan to get together someday.
It is in this agitated state that Curley's wife finds Lennie. She is dressed in a very sexy manner and she says she just wants somebody to talk to. George, however, has warned Lennie not to talk to Curley's wife. George knows that she is a sexually dangerous woman.
When Lennie refuses to talk to Curley's wife, she becomes emotional and begins to tell Lennie about all of her hopes and dreams and speculating out loud on the life she could have had.
When Curley's wife learns the Lennie likes to touch soft things, she leads him to touch her hair. Unfortunately, Lennie does not know his own strength and touches her hair too roughly. When the woman starts to cry out, Lennie panics and ends up killing her.
Afterwards, Steinbeck mentions that Curley's wife had an "ache for attention."
So, at least on the surface, Curley's wife came to see Lennie because she was yearning for someone to talk to and she wanted some attention.