Jem and Scout are expressing their curiousity in their harassment of Boo Radley.
They don't realize at first that they are harassing Arthur "Boo" Radley at all, but think they are actually attempting to help him by drawing him out. They repeatedly say that they believe Boo would be happier if he could unburden himself and be around nice people.
Although Jem and Scout have heard the Boo Radley legends for years, it is the arrival of Dill that spurs their attempts to lure him into the open. Dill is fascinated by the stories, and the children's summer boredom suddenly becomes a distant memory. It is pure inquisitiveness and curiosity that spurs their attempts.
As a child, I remember how much excitement I had when my cousins and I sought to discover who lived in the haunted house down the road. We lived for the thrill of seeing a ghost or even a human being in the house. Scout and Jem and Dill live for the thrill of seeing Boo come out of his house. They have heard all the terrifying stories of how he stabbed his father with the scissors. They just want to get a glimpse of Boo Radley. I agree with post 5. They are just children who have an overactive imagination. All children play games that involve spooky events. I remember that my cousin dared me to touch the porch on the haunted house. I could not turn down a dare.
Also, Boo seems to like the attention. He leaves gifts for the children in the knothole. He stitches Jem's pants. Boo does not seem to mind the attention. He probably lives for the attention. Living in isolation has to be lonely.
It is not until Atticus scolds them that the children even consider their actions as "harassment." For, Boo Radley is perceived by Scout, Jem, and Dill as a "haint," a being who is not exactly human. It takes Miss Maudie and Atticus to convince them otherwise.
Readers must be careful not to read too much into childish actions. Is it not human nature to be curious about the odd? Especially intelligent and imaginative children such as Scout and the boys would naturally explore this unusual aspect of their neighborhood without even considering the consequences--after all, they are children. This episode of To Kill a Mockingbird clearly exemplifies two of the themes of the novel: People must learn to think outside themselves when they are part of a society and understand others, and as one matures, one examines situations from many perspectives.
Just like it happens in any case of bullying, the reason why Boo is getting harassed is because, in some way or another, Jem and Scout feel intimidated by all the things they think of Boo, by his enigmatic persona, and by the stories told about him. Their harassment is their way to combat their fear and take control of the situation, no matter how silly it seems.
Also, they suspect in a way that Boo may be the weakest link between them. Yet, they aren't completely sure: Why not test it? Why not see how far they can get? It is just part of their childish immaturity and their fears as people who are curious about the unknown.
I think that the kids are harassing him so as to be able to prove their bravery. They "know" that he is this monster and that everyone is afraid of him. So if they are able to touch his house and do things like that, it will show that they are not afraid. I think that is why they harass him -- it's to show they're not afraid.
The kids have heard so many legends about this man that their curiosity gets the better of them most of the time. They think he is a peeping tom, a murderer, and that he eats chickens among many other legends. So, these harassing behaviors of trying to send him a note, or sneaking through his backyard to get a glimpse, or trying to leave a series of lemon drops for him to eat in an effort to be led to the kids are just that, efforts to meet him.
The day when Scout rolls in the tire and hears someone laughing compares to Jem finding the pants all sewn up. Each are a positive but mysterious experience with the character of Boo Radley, but the kids aren't quite sure that it is him. The gifts in the knothole were obviously for the kids by the time they get to receiving the soap dolls, so this too makes their intrigue continue. They want to know him. This is why they "harass" him. They also seem to have a suspicion that he may not be a bad guy.