I'm trying to get an array of names stored into a data structure, but I keep getting this odd error of C2661

(error C2661: 'std::basic_istream<_Elem,_Traits>::getline' : no overloaded function takes 1 arguments
with
[
_Elem=char,
_Traits=std::char_traits<char>
]
)

I can't figure out how to fix this error, any help would be appreciated.(code included for reference)
Code:
#include <iostream>
using namespace std;

struct StudentRecords
{
char name;
};

void main()
{
StudentRecords student[5];
for (int s = 0; s < 2; s++)
{
cout << "Enter student name ----> ";
cin.getline(student[s].name );
cout << endl;
}