Use case: Login with a username, navigated to a 2nd factor authentication page to do one of a number of things (i.e. answer a knowledge based question), and then navigated
To preserve cookies on Firefox; create a custom profile (see here for an example) and use it each time when starting new RemoteWebDriver instance. That way Firefox will reuse same profile with all the existing cookies across sessions. This however doesn't save cookies received during the test itself. See the alternative approach below for a solution.
A similar approach works for Chrome - link.
For Internet Explorer instead of a custom profile, ensureCleanSession capability needs to be set to false to prevent cleaning cookies on session start - link.
Alternative solution: Cookies can be also manipulated from within the test itself:
Get all the cookies when test ends:
ReadOnlyCollection<Cookie> cookies = driver.Manage().Cookies.AllCookies;
Store them somewhere. How you do it depends on the automation setup, but usually simple serialization to disk should work just fine.
De-serialize your cookies on test start and add them through the WebDriver:
foreach (var cookie in cookies) driver.Manage().Cookies.AddCookie(cookie);