Find and explain the bugs in the following Python program:
product = 1
i = 1
def factorial(n):
while i <= n:
product = product * i
return product
print('1! =', factorial(1))
print('2! =', factorial(2))
print('3! =', factorial(3))
Your solution must not only fix the program, but also must explain what bugs were present.