input: Write a function to create an application using Python and Flask that allows users to submit form data containing Name, Email, and Phone fields and stores this data in an SQLite database. The application should have a homepage that renders a form and a submit route that processes the form data and stores it in the database. If the form data is successfully stored, the user should be redirected to the homepage.
  
  assert create_flask_app==True
  assert submit_form('John Doe', 'john.doe@example.com', '1234567890')==True
  assert check_database_entry('John Doe', 'john.doe@example.com', '1234567890')==True
  assert submit_form('Jane Smith', 'jane.smith@example.com', '0987654321')==True
  assert check_database_entry('Jane Smith', 'jane.smith@example.com', '0987654321')==True
output: 
  def create_flask_app():
      from flask import Flask, request, redirect, render_template
      import sqlite3
  
      app = Flask(__name__)
  
      def create_table():
          conn = sqlite3.connect('form_data.db')
          c = conn.cursor()
          c.execute('''CREATE TABLE IF NOT EXISTS submissions
                       (name TEXT, email TEXT, phone TEXT)''')
          conn.commit()
          conn.close()
  
      @app.route('/')
      def home():
          return render_template('form.html')
  
      @app.route('/submit', methods=['POST'])
      def submit_form():
          name = request.form['name']
          email = request.form['email']
          phone = request.form['phone']
          conn = sqlite3.connect('form_data.db')
          c = conn.cursor()
          c.execute("INSERT INTO submissions (name, email, phone) VALUES (?, ?, ?)", (name, email, phone))
          conn.commit()
          conn.close()
          return redirect('/')
  
      create_table()
      return app
  
  def check_database_entry(name, email, phone):
      conn = sqlite3.connect('form_data.db')
      c = conn.cursor()
      c.execute("SELECT * FROM submissions WHERE name=? AND email=? AND phone=?", (name, email, phone))
      entry = c.fetchone()
      conn.close()
      return entry is not None
  