The difference comes when you complete the sentence and this example is perhaps not the best way to tell you about it. Let me give you another example,
The cars, which are new, cost more than 2 million
The cars that are new cost more than 2 million
The first sentence says that the all cars cost more than 2 million and add an extra information that they are all new
The second sentence says that the cars that are new cost more than 2 million, thus limiting the cost to describe only the cars that are new.
Summing up, use 'which' with commas if a group of words adds information. Use 'that' if it limits the set of things you're talking about.
If you need more clarification, let me know.