Let $C\subset\mathbb{R}^2$ be a nonempty convex set. A function $f:C\rightarrow\mathbb{R}$ is called
convex if $$ f(\lambda u+(1-\lambda)v)\leq\lambda f(u)+(1-\lambda)f(v), \quad\forall u,v\in C, \forall\lambda\in(0,1); $$
quasiconvex if $$ f(\lambda u+(1-\lambda)v)\leq\max\{f(u), f(v)\}, \quad\forall u,v\in C, \forall\lambda\in(0,1). $$
It is easy to very find that convexity implies quasiconvexity. The reverse implication is not true in general.
Counterexample. The function $$ f(x,y) = \begin{cases} 0 &\mbox{if } \quad0<x<1, y=1, \\ 1 & \mbox{if } \quad\text{otherwise}. \end{cases} $$ is quasiconvex but not convex on $C=[0,1]\times[0,1]$.
$f$ is not convex on $C$. Indeed, we have $(0.5,1), (0,0)\in C$ and $$ f\left(\frac{1}{2}(0.5,1)+\frac{1}{2}(0,0)\right)=f(0.25,0.5)=1>0.5=\frac{1}{2}f\left(0.5,1\right)+\frac{1}{2}f(0,0). $$
$f$ is quasiconvex on $C$. Indeed, let $u, v\in C$. We consider two cases:
Case 1. $u, v\in (0,1)\times\{1\}$
Then, $\lambda u+(1-\lambda)v\in (0,1)\times\{1\}$ for all $\lambda\in(0,1)$ and so $$ f(\lambda u+(1-\lambda)v)=0=\max\{f(u),f(v)\}; $$
Case 2. $u\notin (0,1)\times\{1\}$ or $v\notin (0,1)\times\{1\}$
Then, $\max\{f(u),f(v)\}=1$, and so $$ f(\lambda u+(1-\lambda)v)\leq\max\{f(u),f(v)\}, \quad \forall \lambda\in (0,1). $$
Question.
We would like to construct a function $f(x,y):C\rightarrow\mathbb{R}$ with $C\subset\mathbb{R}^2$ being convex such that:
(1) $f(x,y)$ is not convex on $C$;
(2) $f(x,y)+\lambda y$ is quasiconvex on $C$ for all $\lambda\in\mathbb{R}$ .
Thanks for all helping and comments.