Can I use online check-in if I am travelling with an infant?

Yes. Online check-in is possible for the accompanying adult passenger.

Related questions

What are the ticketing rules for child and infant passengers on Emirates?
What are the online payment rules?
What are the online payment rules?