void addCookie(String url, Cookie cookie) {
        URL urlObj;
        try {
            urlObj = new URL(url);
        } catch (MalformedURLException e) {
            throw new SelendroidException("Error while adding cookie. ", e);
        }
        String domain = "http://" + urlObj.getHost() + cookie.getPath();
        SelendroidLogger.info(domain);
        if (!domain.endsWith("/")) {
            domain = domain + "/";
        }
        cookieManager.setCookie(domain, stringifyCookie(cookie));
    }
Adds a cookie to a URL domain.

@param url to add the cookie to
@param cookie Cookie to be added
selendroid-server/src/main/java/io/selendroid/server/model/SessionCookieManager.java