input: Write a function to create a Flask application that allows users to submit form data with elements Name, Email, and Phone, and stores the submitted data in an SQLite database. The function should return the Flask application object. If the database does not exist, the function should create it with the necessary table structure.
  
  from flask import Flask, render_template, request, redirect
  import sqlite3
  
  def create_form_submitter():
   app = Flask(__name__)
  
   @app.route('/')
   def home():
    return render_template('index.html')
  
   @app.route('/submit', methods=['POST'])
   def submit():
    name = request.form.get('name')
    email = request.form.get('email')
    phone = request.form.get('phone')
    
    conn = sqlite3.connect('data.db')
    cur = conn.cursor()
    
    cur.execute("CREATE TABLE IF NOT EXISTS data (name TEXT, email TEXT, phone TEXT)")
    cur.execute("INSERT INTO data (name, email, phone) VALUES (?, ?, ?)", (name, email, phone))
    conn.commit()
    
    return redirect('/')
      
   if __name__ == '__main__':
    app.run(debug=True)
  
   return app
  
  assert create_form_submitter().name == '__main__'
  assert create_form_submitter().template_folder == 'templates'
  assert create_form_submitter().static_folder == 'static'
  assert create_form_submitter().url_map.bind('localhost').match('/') == ('home', {})
  assert create_form_submitter().url_map.bind('localhost').match('/submit') == ('submit', {'POST': None})
  assert create_form_submitter().config['DEBUG'] == True
output: 
  def create_form_submitter():
   app = Flask(__name__)
  
   @app.route('/')
   def home():
    return render_template('index.html')
  
   @app.route('/submit', methods=['POST'])
   def submit():
    name = request.form.get('name')
    email = request.form.get('email')
    phone = request.form.get('phone')
    
    conn = sqlite3.connect('data.db')
    cur = conn.cursor()
    
    cur.execute("CREATE TABLE IF NOT EXISTS data (name TEXT, email TEXT, phone TEXT)")
    cur.execute("INSERT INTO data (name, email, phone) VALUES (?, ?, ?)", (name, email, phone))
    conn.commit()
    
    return redirect('/')
      
   if __name__ == '__main__':
    app.run(debug=True)
  
   return app
  