input: Write a function to create a Flask application that accepts form data (Name, Email, Phone) via a POST request and stores it in a SQLite database. Return the Flask application object and ensure that the form submission saves the data to the database.
  assert create_flask_app("data.db", "data")==<Flask 'main'>
  assert create_flask_app("data.db", "data").__name__=="main"
  assert create_flask_app("data.db", "data").url_map.converters['default']=='default_flask_route_converter'
  assert create_flask_app("data.db", "data").template_folder=="templates"
  assert create_flask_app("data.db", "data").static_folder=="static"
output: from flask import Flask, request, jsonify
  import sqlite3
  
  def create_flask_app(db_name, table_name):
      app = Flask(__name__)
  
      def init_db():
          conn = sqlite3.connect(db_name)
          cursor = conn.cursor()
          cursor.execute(f'''CREATE TABLE IF NOT EXISTS {table_name}
                            (id INTEGER PRIMARY KEY AUTOINCREMENT,
                             name TEXT NOT NULL,
                             email TEXT NOT NULL,
                             phone TEXT NOT NULL)''')
          conn.commit()
          conn.close()
  
      @app.route('/submit', methods=['POST'])
      def submit_form():
          data = request.form
          name = data.get('Name')
          email = data.get('Email')
          phone = data.get('Phone')
  
          conn = sqlite3.connect(db_name)
          cursor = conn.cursor()
          cursor.execute(f"INSERT INTO {table_name} (name, email, phone) VALUES (?, ?, ?)", (name, email, phone))
          conn.commit()
          conn.close()
  
          return jsonify({"status": "success", "message": "Data saved successfully"})
  
      init_db()
      return app