To be elegible for the amateur draft you have to meet one of the following criteria:
1. GRADUATED from high school.
2. Completed your junior year if you attend a 4-year college.
3. Attended at least 1-year of junior college.
4. Be 21 years old.
Based on this information, which is available at mlb.com, I think if a player has not graduated from high school he couldn't be drafted until he turns 21.