I was reading the general form of Euclid's lemma which states:
If $a \mid bc$ and $a$ is relatively prime to $b$ then $a \mid c $
I don't really understand why the "relative prime" condition is there.
If for instance we take as $a = 49$ and $b = 91$ then $\gcd(a,b) = 7$
So then we would have:
$ax + by = 7 \Leftrightarrow cax + cby = 7c$
We know that $a \mid cax$
We also know that $a \mid bc \Rightarrow a \mid cby$
So $a \mid 7c$
But we already know that $a \nmid 7$ because $\gcd(a, b) = 7$ so $a\mid c$
So it seems to me that we can prove the lemma without specifying prime relativity.
What am I doing wrong here?
Yes, you need coprime.
Proof. Let $d=\gcd(a,b)$; then we can write $a=da'$ and $b=db'$, with $\gcd(a',b')=1$. Let $c=a'$. Then $ba'= db'a' = da'b' = ab'$, so $a|bc$. However, $a$ does not divide $a'$, since $a'\lt a$ (because $d\gt 1$). $\Box$
So absolutely nothing short of "$a$ and $b$ coprime" will allow you to go from $a|bc$ to $a|c$. If $a$ and $b$ are not coprime, then there always exist values of $c$ that make the antecedent true (that is, $a|bc$), but the consequence false (that is, $a\nmid c$).
As to what you present: First, that $7$ is a linear combination of $a$ and $b$ does not, by itself, mean $\gcd(a,b)=7$; it means $\gcd(a,b)$ divides $7$. And you cannot go from $a|7c$ and $a\nmid 7$ to $a|c$; that is, after all, what you claim to be trying to prove, and you cannot when $\gcd(a,7)\neq 1$ (see above).
What you have correctly established the following:
You may think of that as a generalization of Euclid's lemma (since it yields Euclid's Lemma when $\gcd(a,b)=1$); but you cannot go from that to deduce $a|c$.
As to proving that statement, what you have works: let $d=\gcd(a,b)$. There exist $x,y\in\mathbb{Z}$ such that $ax+by=d$, hence $axc+bcy=dc$. Since $a|axc$ and $a|bcy$, then $a|dc=\gcd(a,b)c$, as desired.
But that's where you get stopped. You cannot go further if $\gcd(a,b)\neq 1$.