Hi Ramya, we use RemoteWebdriver in Selenium Grid because if we use webdriver (FirefoxDriver / ChromeDriver), it will just assume that the communication to the browser is local. For example:
Webdriver driver = new FirefoxDriver();
Using this, driver will access Firefox browser which is available on the local machine. Now if we will use RemoteWebDriver, it requires us to specify where the Selenium Server is located and on which web browser we want to execute our tests. For example,
WebDriver driver = new RemoteWebDriver(new URL("http://localhost:4444/wd/hub"), DesiredCapabilities.firefox());
Here in above statement , it is specified that Selenium Server is running on localhost with the default port 4444 and execute on firefox browser. In the same fashion, we can run selenium server on one machine as Hub and execute selenium tests on other machine by registering to the node by specifying parameters.