While Romeo is the main protagonist of the story, Juliet is a secondary protagonist; you could also call her the heroine of the story. A protagonist is the main character of a story, the one that the author focuses on. Occasionally, an author chooses to use parallel protagonists; this is especially true for stories about lovers or stories about sisters or other pairs, like Jane Austen's Sense and Sensibility. Romeo is arguably the main protagonist as he is the one with the fatal character flaws. Romeo and Juliet is a tragedy and, therefore, needs a tragic hero. A tragic hero, by Aristotle's acceptable definition, is a character of high social standing, such as a king, prince, or a lord's son, like Romeo. A tragic hero is also a character who is generally virtuous but also has a character flaw that leads to his/her demise. Romeo's character flaws are that he is stubborn and far too driven by his passionate emotions rather than by reason. Unlike his cousin Benvolio, Romeo behaves irrationally while Benvolio behaves calmly and rationally. While Juliet allows herself to get swept up in Romeo's passionate feelings for her, she does not have the same character flaws Romeo has. She actually tries to behave far more rationally than Romeo does. Since Juliet's death is more of a matter of circumstance rather than any character flaw, Juliet is not the tragic hero. Since Romeo is the tragic hero rather than Juliet, Romeo is the central protagonist while Juliet is a secondary lead character.
Since Juliet, at least at first, behaves and thinks far more rationally than Romeo, another role of Juliet's is to serve as Romeo's dramatic foil. A dramatic foil is a character that contrasts with another, bringing out the qualities or even flaws of the other character. We especially see Juliet behaving far more rationally than Romeo in the famous balcony scene, Act 2, Scene 2. In this scene, Romeo allows himself to be governed purely by his emotions. He allows himself to equate love with purely physical attraction, as we see when he goes on and on about Juliet's beauty, as in the lines, "But soft! What light through yonder window breaks? / It is the East, and Juliet is the sun!" (II.ii.2-3). It is quite evident that Juliet feels a strong physical attraction for Romeo too, but she has the sense to try and dissuade him from making promises of love so soon, saying instead, "Although I joy in thee, / I have no joy of this contract to-night" (122-123). She also shows her rationality when she refuses to allow the relationship continue unless she knows that Romeo is proposing marriage. Hence, Romeo is purely emotional and irrational while Juliet remains level-headed and rational, proving that Juliet's other purpose is to serve as Romeo's dramatic foil.
Juliet's role in Romeo and Juliet was to carry out the cliche housewife role which was common between the 14th century Italy, or the 1300's where Romeo and Juliet was expected to have taken place. This can be seen through the arranged marriage with Paris where she has no rights in who she wants to marry.