Suppose you have two $I(1)$ series, $y_{1,t}$ and $y_{2,t}$. They can be decomposed into
\begin{aligned}
y_{1,t} &= x_{1,t} + s_{1,t}, \\
y_{2,t} &= x_{2,t} + s_{2,t}; \\
\end{aligned}
where $x_{1,t}$ and $x_{2,t}$ are stochastic trends while $s_{1,t}$ and $s_{2,t}$ are stationary components.
If $y_{1,t}$ and $y_{2,t}$ are cointegrated, then $x_{1,t} \equiv c x_{2,t}$ for some $c$. Without loss of generality, let us assume $c=1$. That means $y_{1,t}$ and $y_{2,t}$ share the same stochastic trend $x_{t}:=x_{1,t}=x_{2,t}$ and we can write \begin{aligned}
y_{1,t} &= x_{t} + s_{1,t}, \\
y_{2,t} &= x_{t} + s_{2,t}. \\
\end{aligned}
If you take $y_{1,t}$ and $y_{2,t-h}$ for some $h>0$, will they be cointegrated?
\begin{aligned}
y_{1,t} - y_{2,t} &= ( x_t + s_{1,t} ) - ( x_{t-h} + s_{2,t-h} ) \\
&= ( x_t - x_{t-h} ) + ( s_{1,t} - s_{2,t-h} )
\end{aligned}
which is a sum of two stationary series, because a difference at lag $h$ of $x_t$ is stationary and a difference of two stationary series $s_{1,t}$ and $s_{2,t-h}$ is stationary. Thus we have found a stationary combination of $y_{1,t}$ and $y_{2,t-h}$, which means they are cointegrated. In a similar way you could also show that if $y_{1,t}$ and $y_{2,t-h}$ are cointegrated, then $y_{1,t}$ and $y_{2,t}$ are cointegrated, too.
Thus in theory you can test for cointegration either between $y_{1,t}$ and $y_{2,t}$ or $y_{1,t}$ and $y_{2,t-h}$ and the answer should be the same. Empirically the answer may differ, but hopefully you have a large enough sample so that it does not differ in your case.
Which pair to test is then a matter of taste from the statistical point of view. So probably you want to test the pair that makes the most subject-matter sense.
P.S. This holds for the case of $y_{1,t}$ and $y_{2,t}$ being $I(1)$. If $y_{1,t}$ and $y_{2,t}$ are $I(d)$ with $d>1$, the answer will be different, but similar reasoning as above applies.