They both translate as could in English but as Albert says podia in the past and podría in the conditional. Podia could also translate as "was able to".
These examples may help: I couldn't finish my homework. - No podía terminar los deberes. If I had more time I could do my homework better. - Si tuviera mas tiempo, podría hacer los deberes mejor.