ag.algebraic geometry – One arrow reversed version of smooth extension problem

Suppose $Y$ is an irreducible quasi-projective $k$-scheme of dimension $geq 1$, which may be singular or non-reduced, etc., and let $U subset Y$ be a nonempty open subscheme.

There are various “extension” problems from $U$ to $Y$. For instance, people often need to extend a coherent sheaf or a perfect complex, etc. over $U$ to one on $Y$. Usually the “structures” are “over” $U$, or $Y$.

While working on a problem, I somehow bumped into the following kind of funny situation, where we have “structures” with arrows “reversed” in a sense.

So, here is the precise question:

For the above open immersion $iota: U subset Y$, suppose there is a closed immersion $U hookrightarrow Z$ into a smooth $k$-scheme. Then can we find smooth
$X$ together with a closed immersion $Y hookrightarrow X$, such that $X$
restricted to $U$ is an open neighborhood of $U$ in $Z$?

Here, the last part means that there exist (1) an open $X’ subset X$ and (2) an open neighborhood $Z’subset Z$ of $U$, such that $X’ cap Y= U$ and we have an isomorphism of $X’$ with $Z’$ under $U$.

At first sight, I thought it should be an obvious consequence of some usual smooth compactifications (via Nagata compactifications + desingularizations) but then I realized the situation was not like that. I still hope that it can be resolved using some clever resolution tricks, but I am running out of steams.

In case this turns out to be false, can we weaken the requirement

“we have an isomorphism $X’simeq Z’$ under $U$

to

“we have a morphism $X’ to Z’$ under $U$“?