Cannot update request in Slim container

I use…

// update uri to request.
$uri = $uri->withPath($new_path);
$request = $request->withUri($uri);
// remove and then set new "request".
$this->CI->offsetUnset('request');
$this->CI->offsetSet('request', $request);

Add after this topic How to apply new $_SERVER['REQUEST_URI'] to Slim?