Hi Sriram,
Which browser are you using where you see this?
In Firefox, when I run:
utag.loader.SC("utag_main", { mycookie: "abcdefghij/test.html;exp-session" });
I see the mycookie parameter applied to the utag_main namespace with the correct value. See 1st attached screenshot.
If I then run:
utag.loader.SC("utag_main", { mycookie: "abc/test.html;exp-session"
I see the mycookie parameter correctly updated with the new value. See 2nd attached screenshot.
I should note that I'm surprised the RC call is actually returning a result. That method is really only meant to be used on page landing to read document.cookie and inject the 1st party cookies into the data layer.
What I would suggest doing is also setting the data layer value and read that:
utag.loader.SC("utag_main", { mycookie: "abcdefghij/test.html;exp-session" });
utag.data["cp.utag_main_mycookie"]="abcdefghij/test.html";
Then if you want to read the cookie value you can just reference the data_layer instead of having to re-parse all cookies and adding more logic.