In general, you cannot use plain OLS on market data to estimate demand elasticity. The one, unusual, exception would be if supply was not price sensitive (the supply curve was a straight up and down line with the same price for every quantity). The same goes for supply elasticity. See this link which explains it well. You can also see Greene's Econometric Analysis textbook (edition 5 or 7, 5 is available for free in pdf online) which covers this topic thoroughly. I will make an informal attempt at explaining below.
Suppose we want to estimate a linear supply and demand curve, something like;
$$
\begin{array}{llc}
q^s_t &= \alpha_0 + \alpha_1 p_t + \alpha_2 w_t+ u_t&(Supply) \\
q^d_t &= \beta_0 + \beta_1 p_t +\beta_2 y_t+ v_t&(Demand)
\end{array}
$$
Where $q^s_t=q^s_t$ is log quantity, $p_t$ is log price, $w_t$ are the log input costs, and $y_t$ is log consumer income. (you can have other explanatory variables too if you like, but this is the basic case).
With the above specification, the demand and supply price elasticities are
$$
\frac{\partial q^s_t}{\partial p_t}= \alpha_1\;\;(Supply)\;\;\;\;
\frac{\partial q^d_t}{\partial p_t} = \beta_1\;\;(Demand)
$$
BUT THE ABOVE CANNOT BE ESTIMATED WITH OLS because price is endogenous. Why? because, for the market to clear, price and quantity are decided simultaneously with both demand and supply side mechanisms. For example, a firm may change it's prices in response to increases or decreases in it's competition. Such variation in prices is not exogenous but rather caused by shifts in $q^s_t$. This reverses the order of causality that would be implied by an OLS regression model of the above supply and demand functions.
Demand elasticity is generally upward bias when estimated with OLS and I am pretty sure supply elasticity is downward bias (but check the references above too, I think the bias is usually attenuating (toward 0) in all cases).
There are two prominent econometric methodologies for estimating demand/supply curves. These are
Structural equation modeling: $$ \begin{bmatrix}q_t \\ p_t \end{bmatrix} = \begin{bmatrix}\pi_0 \\ \omega_0 \end{bmatrix} + \begin{bmatrix}\pi_1 & \pi_2 \\ \omega_1&\omega_2 \end{bmatrix}\begin{bmatrix}w_t \\ y_t \end{bmatrix}+\begin{bmatrix}e_{1,t} \\ e_{2,t} \end{bmatrix}$$ which is a multivariate likelihood.
Instrumental Variables (as suggested in your question). In the case of demand this is: $$\begin{array}{llc}
p_t &= \omega_0 + \omega_1 w_t + \omega_2 y_t + e_t&(First\;Stage) \\
q^d_t &= \beta_0 + \beta_1 \hat p_t +\beta_2 y_t+ v_t&(Second\;Stage)
\end{array} $$
$w_t$ works as an instrument because it acts like an exogenous “shifter” in supply. The basic idea is that by moving the supply curve up and down and recording the equilibrium quantities and prices, we can trace out the demand curve. The assumption here is that the suppliers cannot control their input costs (this is not always true when suppliers can negotiate their input costs as in oligopsony but we assume it is here). For supply we would use the same methodology but with $y_t$ as the instrument.