You first must apply to study at a USCIS-approved school in the United States. When you contact a school that you are interested in attending, you should be told immediately if the school accepts foreign national students.
If you are accepted, the school should give you USCIS Form I-20 A-B/ID (Certificate of Eligibility for Nonimmigrant (F-1) Student Status – for Academic and Language Students).
If you require a visa, then you should take the USCIS Form I-20 to the nearest U.S. consulate to obtain a student visa. Only bring the USCIS Form I-20 from the school you plan on attending for visa processing at the U.S. consulate.
You must also prove to the consulate that you have the financial resources required for your education and stay in the United States.