Can a non-resident USA visa holder apply to attend in the PE Exam?
Residency status typically isn't a requirement for most states in the US regarding applying for a professional engineer license. That said, based upon the information you have provided, I don't believe that you meet the typical qualifications to apply for the exam. Requirements will sometimes vary based upon which US state you are applying within.
Typical requirements are:
Graduate of a baccalaureate engineering program accredited by the Engineering Accredita on Commission of
ABET (EAC/ABET).
Taken and passed the NCEES Fundamentals of Engineering Exam.
Completed four (4) years of satisfactory engineering experience under a licensed PE following the date you received an engineering degree.
As far as I know, ABET doesn't accredit programs outside of North America, so you likely miss the first qualification. And I strongly suspect you haven't met the second and third qualifications regarding the FE exam and the supervised experience requirement.
So you're pretty much at "No, can't happen" at this point because you're ineligible to apply for the PE exam.
It's possible that you can apply for licensure by comity. But that requires you to be licensed as a professional engineer in another region, and that the US state that you wish to receive licensure within has a comity agreement with that other region.
For the sake of completeness, I'll address your other two questions although they're not as germane at this point.
What precautions/preparations I need to take to pass the PE Exam on the first attempt?
I have read many articles on PE Exam. I have heard that XYZ book1 is necessary to pass Civil Engineering PE Exam. Is that true?
The Civil PE exam has one of the lower first time pass rates as compared to other PE exams. I know multiple Civil PEs, and all of them put a very significant amount of effort into studying practice exams and questions ahead of the actual exam. Hundreds of hours of study ahead of time is not unusual.
The Civil PE exam also probably has one of the worst reputations for the sheer number of reference volumes required in order to successfully pass the exam. Civil Engineers need to be able to quickly look up relevant codes and standards during the exam, and there is a wide body of material that has to be covered.
The Lindeburg book you linked is one of many reference manuals that are worth considering ahead of taking the exam. And there are a few other commercial entities that provide sample exams. Each set of PE exams is a bit unique though, and each engineer's experience is different. I have yet to see a valid list of universally necessary reference materials that would "guarantee" a first time pass of the exam.
Ultimately, you'll need to assemble your own set of reference materials based upon your experience and your expectations regarding the exam. Again, the practice examples and suggestions from NCEES can be invaluable here.
1 Aside, I intentionally replaced the title mentioned with a more generic placeholder. There's lots of books that are supposedly required.