To me, a research visit means just that: you go somewhere for some period of time to do research, usually because you want to work together with a specific person or group. It means the same for PhD students as it does for professors. As Austin Henley mentions in his answer, it is common that the visitor will also give a seminar or colloquium talk.
For a PhD students such a research visit can have a couple of benefits. First, it allows you to meet other people in your field and work with them, thus expanding your network. This is important later on, when you are trying to find a postdoc or faculty position. More importantly, it can be beneficial to your research. It can be a great opportunity to work closely with experts in your field, for example on parts of you thesis your advisor knows less about.
As for duration, there is a wide range. In my field, mathematics, I would say up to about one or two weeks is fairly typical, but longer visits are not uncommon. Of course, for long visits funding becomes an issue, and it is usually necessary to attract external funding. There are various programs to fund such visits, for example as part of an exchange program. Sometimes for a longer visit you can get an "official" position at the university as a visiting student. I think this is typically more of an administrative thing, so that you for example can make use of the library.
Finally, it could also mean having a "visiting researcher" or "visiting professor" position. This usually means a longer term position, for example 1-2 years. In my field such positions are either basically postdoc positions (i.e., non tenure-track positions), or for people that are on sabbatical that visit another university for an extended period of time. Typically such positions also include some teaching duties.