When we do linear regressions, we often add powers of variables to account for the non-linearity effect of that variable while still staying in the linear regression framework. As long as $X,X^2$ are not perfectly collinear (ie if X is binary), then I may want to consider
$$Y = \alpha_0 + \alpha_1X + \alpha_2X^2 + e_1$$
instead of
$$Y = \beta_0 + \beta_1X + e_2$$
Why would I do this? Well precisely to allow for a quadratic effect of $X$. Let's relate it directly to your question of outcome being mortality, and covariate being age. In the linear specification (the second one), let's suppose that $\beta_1 > 0$ is positive. That means that higher age always means higher mortality. Seems fine right? Older people die more. But wait!! Whenever researchers looked at mortality rate by age, they notice something curious: very young children have a very high mortality rate, then it dips in the teens up to the 50s, and then it goes up again. Why? Well infant mortality is a very big problem, especially in developing nations, but more generally, a 1 year old is more likely to unfortunately pass away than a 25 year old. One reason is that there are many diseases and complications that threaten a newly born, but conditional on making it past the first few years, they are no longer going to kill you (developed immunity, stronger body, etc). This evidence suggests that I want to somehow allow for young ages to have higher mortality, but then it slopes down to a low mortality rate, and then rises again later in maybe the 50s+. But that kind of curve is precisely a quadratic curve. For example, $x^2-40x+400$ is the curve where mortality is $0$ at age $20$, but increases on either side... by specifying a quadratic form as in the first form I wrote, you can estimate what these coefficients should really be according to the data.
There are many situations where a similar concept arises.