Can I connect an analog sensor like ACS712 to a digital input pin on Arduino?
You should use a comparator. Specifically ACS712 has 0A at 2.5V and maximum current at 0.5V and 4.5V, so you don't have much to do with it with digital input. But if you are looking for overcurrent condition- just use comparator(s).

By the way, pay attention, that the current you are measuring should be within ACS712 bandwidth, otherwise you will miss the peaks.