给出一个名字列表和一个字符串，编写一个函数来计算字符串中出现的每个名字在列表中出现的次数。
```
names = ['John', 'Jane', 'Sam', 'Kate']
text = 'John and Jane are brother and sister, Sam is their cousin, Kate is their friend.'
```
```python
def count_names(names, text):
    name_counts = {}
    for name in names:
        count = text.count(name)
        name_counts[name] = count
    return name_counts

names = ['John', 'Jane', 'Sam', 'Kate']
text = 'John and Jane are brother and sister, Sam is their cousin, Kate is their friend.'

print(count_names(names, text))
# {'John': 1, 'Jane': 1, 'Sam': 1, 'Kate': 1}
```