Setting describes when and where a story takes place. For example, Wuthering Heights is set in Yorkshire (physical place) in the late eighteenth-century (time period). Depending upon the story, setting can be defined broadly (Star Wars is set a long time ago in a galaxy far, far away) or quite exactly (The Haunting of Hill House is set in an isolated Victorian mansion in late 1950's America). Of course, stories can be set in more than one place: Mary Shelley's Frankenstein has its titular doctor pursuing his Creation from Switzerland to the North Pole.
Setting can help create tone, which is how a story makes the audience feel. Taking The Haunting of Hill House as an example again, the isolated house in which the story is set creates feelings of claustrophobia and unease in the viewer. The house's old-fashioned furniture is often described as suffocating and overbearing. These qualities reflect the setting's effect on the mind of Eleanor the protagonist, who believes the house is haunted and calling to her. The novel's setting is vital to creating gothic mood. Were it set in a cheerful modern apartment with big open windows in the middle of New York City, the story would not be as effective.