US graduate school: expected proficiency and competency in the area of specialization at the beginning of the program
This will vary widely from program to program (so much so that this question is borderline &quot;off topic&quot; in this forum), so your best bet would be to discuss this with members of the department where you are thinking of applying (even/especially students). Still, some thoughts...

I feel that I may lack some of the more general knowledge that would normally be expected from a computer science graduate

My biggest concern is your skills in analytical math (i.e., writing proofs). If you are starting from zero and expected to take difficult classes in theoretical computer science, this could be difficult. If your gaps are elsewhere (or such courses are not required by your program), it may be easier to fill these gaps through self-study.

Is it socially acceptable to be spending a significant amount of time during the first 1-2 years of the Ph.D. doing courses and, generally, exploring the subject widely?

In my experience, these classes are very difficult, so it is socially acceptable to spend every waking moment trying desperately to pass. Research is for later years. Of course, this will vary school to school.

Should I make it reasonably apparent in my applications (in the personal statement) that &quot;I am interested in studying such and such subjects in-depth and I am pleased that the department XYZ provides a unique opportunity to do so&quot;.

Well, your application to a CS PhD program makes it reasonably apparent that you want to study the subjects in detail, and your application to department XYZ makes it clear that you approve of XYZ's program. So, I'm not sure what this sentence buys you. It's also unclear what you find to be &quot;unique&quot; (i.e., one-of-a-kind) about this particular program; offering courses in CS does not make a CS department unique.

The reasoning behind it is that I do not wish to be perceived more competent than I am in the broad area of computer science.

I didn't get this at all from your quote. If this is what you want to communicate, I would phrase it as: &quot;I do not wish to be perceived more competent than I am in the broad area of computer science.&quot;
Snarking about the language aside, I would suggest that you omit this from your application. Attempting to give a balanced picture of your strengths and weaknesses is perhaps a good idea, but recall that your goal during the application is to sell the program on you. If you yourself have doubts about your ability to be successful in the program, it is better to resolve these outside of the application process (i.e., either before applying, or after being admitted).

I am interested in what are the general expectations from the Ph.D. students with regard to the ratio of the time spent doing coursework/teaching/research

Again, this will vary from program to program, but as a general guideline, I would say 80% courses, 20% teaching, 0% research for the first year, leading to 100% research by the end.