As to its original origins, I can only really speculate - Wikipedia, with a citation, credits the phrase to an English lawyer Sir William Garrow, who lived during the mid 1700's.
That said, the phrase is expressly adopted by many jurisdictions now, including your home state, Illinois. Section 3-1 of the Illinois Criminal Code states that "Every person is presumed innocent until proved guilty. No person shall be convicted of any offense unless his guilt thereof is proved beyond a reasonable doubt."
So, this is probably the one rule of law the TV shows may actually be representing correctly.Ask a similar question