A foil is a character who contrasts with another, usually the protagonist. The qualities and characteristics of the two characters are in opposition and this is exposed by how they act and what they say. A foil is mostly used to highlight the traits of the character who is the antithesis of the protagonist.
In terms of the above, then, Cassius is the opposite of Brutus. This is indicated in Act l, scene ll, firstly by his statements about Caesar. He clearly resents the general and makes a number of derisive remarks about him, stating that Caesar is neither his nor Brutus' equal, so why should they bow to his authority? He is extremely cynical and his comments are obviously made to influence Brutus and provoke him into joining the conspiracy to get rid of Caesar. Cassius' remarks are clearly self-serving. He is more concerned about individual power and status than the greater good.
Brutus' mild responses to Cassius' assertions are a clear indication that he does not entirely share his sentiments, although he does somehow fear Caesar's rise to power. He does, however, declare that he will consider whatever Cassius has to say, and will probably say, but that he does not wish to make any specific decision at the time. At the end of the scene the two part company with the promise of meeting again.
In addition, Cassius declares that Caesar truly loves Brutus and dislikes him:
Caesar doth bear me hard; but he loves Brutus:
If I were Brutus now and he were Cassius,
He should not humour me.
In contrast, Caesar expressed his suspicions of Cassius to Antony in scene l. He clearly indicated his distrust by mentioning that Cassius had a 'lean and hungry' look and that he'd rather be surrounded by fat men who were comfortable with their lot and had no ambition to achieve authority and power. He believed that Cassius was dangerous because he, 'thinks too much.'
A subtler contrast is indicated in the actions of the two men. Throughout Act l, Brutus is consistently interested in events surrounding Caesar and he continuously wishes to know what is happening, such as when he hears the crowd cheering when Caesar is offered the crown. This shows that whatever Brutus decides is carefully considered, and he wishes to learn about the circumstance of those whose destiny he might affect. His affection for Caesar is also displayed in these actions.
Cassius, on the other hand, is focused on furthering his plot and consults with a number of other conspirators throughout the Act. He also persuades Casca in scene lll, for example, to become part of his scheme. He is overwhelmed by bitterness and ambition and is determined to succeed in his malicious plan.
A lot of this has to do with their motivations. Cassius is motivated by jealousy. He is clearly jealous of Caesar's power and feels that Caesar is weak and doesn't deserve the power he has. When he talks about having to save Caesar from drowning when they were younger, it shows that Cassius feels he is better than Caesar, but that he is always put below Caesar. When talking about saving Caesar from drowning, Cassius says that even though he had to save him, "Cassius is A wretched creature, and must bend his body If Caesar carelessly but nod on him," which again shows his jealousy and contempt of Caesar's position.
Brutus on the other hand is motivated by his feelings of loyalty toward Rome. Although Caesar is a close friend of Brutus, Brutus can see that Caesar in power would not be the best thing for Rome. Brutus is not considering joining the conspiracy for personal gain, but because he feels it is the best thing for his beloved Rome.