In literature, a character foil is one who contrasts with another character (usually the protagonist) in order to illuminate certain qualities in that character. We can see how this applies to Julia and the central character, Winston, in 1984.
Although Julia and Winston are both rebellious and become lovers, they are quite different in other ways. Julia is young, energetic and attractive, while Winston is a good ten years older, physically frail and wholly unprepossessing in appearance.
More importantly, Julia and Winston rebel for essentially different reasons. Julia strikes out because she wants her freedom, to have the good things in life: sex, nice things to eat and wear, and so on.
Julia, then, exists very much in the material world, concerned with satisfying her instincts and appetites. This is why she rebels against the Party. Winston, on the other hand, rebels on an intellectual and philosophical level. He wants to see the ideas of the Party defeated, and society transformed; he does not think so much about his own personal needs as he is always preoccupied with bigger issues. He is not concerned simply with the immediate and the practical, as Julia is.
Julia cannot always understand Winston, but she proves to be a loving companion as long as their affair lasts, and she is equally aware that eventually they will both be caught and killed. However, she doesn’t fret about this, she prefers not to think about it at all. While Winston muses that they are effectively dead from the moment that they go against the Party, Julia replies ‘prosaically’ that ‘We are not dead yet’ and urges him to live in the moment and ‘stop talking about dying’, the inevitable end (Part II, chapter 3).