Headless Chrome driver unable to fetch Instagram page in python Selenium driver

I tried to login and scrape a few details from my Instagram page in Python. I wanna do it in the headless mode because I'm going to deploy it in Heroku. So when I try to login using this code in the headless Chrome driver, the Instagram login page is not fetched. I have provided the screenshot also.

def login_insta(driver,username,password):
    driver.get("https://www.instagram.com/accounts/login")
    time.sleep(5)
    driver.save_screenshot('scrnsh.png')
    driver.find_element_by_xpath(
        "//input[@name='username']").send_keys(username)
    driver.find_element_by_xpath(
        "//input[@name='password']").send_keys(password)

    driver.find_element_by_xpath("//button/div[text()='Log In']").click()
    print("Logged in")


options = Options()
PATH = r"C:\Users\pcname\Downloads\chromedriver"
options.add_argument("--headless")
options.add_argument("--disable-dev-shm-usage")
options.add_argument("--no-sandbox")
options.add_argument('--disable-gpu')
driver = webdriver.Chrome(executable_path=PATH, chrome_options=options)

login_insta(driver,"name","pass")

Screenshot

The screenshot said "Error Please wait a few minutes before you try again" This error doesn't occur with the headlesss Firefox driver, I don't how to add Firefox buildpacks in Heroku. I have recent Chrome driver version. Please help me solve this issue.

Or if you can suggest buildpacks for Firefox for Heroku, and the steps to add them, it would be very helpful. Thank you!