In Act II, Scene 2, Shakespeare's use of prose slows down the brisk pace of Act I and the first scene of Act II. This slower pace allows Shakespeare to establish Claudius's guilt as the murder of King Hamlet, and to begin the exploration of Hamlet's tortured mental state, a state caught between love, grief, and the desire for revenge against Claudius and the treachery of his former friends, Rosencrantz and Guildenstern.
In this second act, the conversations in prose allow for the introduction of a couple of motifs in "Hamlet": The inane conversation between Polonius and Hamlet introduces the motif of appearances differing from inner qualities as Hamlet feigns madness and Polonius plans to use Ophelia to spy upon Hamlet. In his conversation with his old friends, Rosencrantz and Guidenstern, Hamlet gets them to confess that they have been sent to spy on him. However, their loyalty to Hamlet presents a problem to the reader later in Act V when he betrays them.
Likewise, the converstation with the players about the child actors introduces the motif of youth rising up to supercede their elders. Since the mention of boys playing the roles of women is present, the motif of illusion versus reality is introduced, as well. In short, the prose of Act II is an instrument of introduction for serveral motifs.